Example #1
0
 /**
  * Check and load the files if necessary.
  *
  * @return void
  */
 private function _loadFile()
 {
     $oFile = new File();
     $sFileNamePath = PH7_PATH_FRAMEWORK . 'Core/License.class.php';
     $bIsExpiredFile = $oFile->modificationTime($sFileNamePath) + VDate::setTime('+1 month') < VDate::getTime();
     if (!$oFile->existsFile($sFileNamePath) || $bIsExpiredFile) {
         if ($bIsExpiredFile) {
             $oFile->deleteFile($sFileNamePath);
         }
         $this->_downloadFile($sFileNamePath, $oFile);
     }
     unset($oFile);
 }