Beispiel #1
0
     $arLoadModules = array();
     if (strlen($load_modules) > 0) {
         $arLoadModules_tmp = explode(",", $load_modules);
         for ($i = 0; $i < count($arLoadModules_tmp); $i++) {
             $arLoadModules_tmp[$i] = Trim($arLoadModules_tmp[$i]);
             if (strlen($arLoadModules_tmp[$i]) > 0) {
                 $arLoadModules[] = $arLoadModules_tmp[$i];
             }
         }
     }
     if (count($arLoadModules) <= 0) {
         $strErrorMessage .= GetMessage("SUP_NO_LOAD_MODULES") . " [PU301]. ";
         CUpdateSystem::AddMessage2Log(GetMessage("SUP_NO_LOAD_MODULES"), "PU301");
     }
     if (strlen($strErrorMessage) <= 0) {
         if (!CUpdateSystem::LoadModuleUpdates($arLoadModules, $strErrorMessage, LANG, $stableVersionsOnly)) {
             $strErrorMessage .= GetMessage("SUP_UPD_LOAD_BREAK") . " [PU302]. ";
             CUpdateSystem::AddMessage2Log(GetMessage("SUP_UPD_LOAD_BREAK"), "PU302");
         }
     }
 } else {
     $archiveFileName = $_SERVER["DOCUMENT_ROOT"] . "/bitrix/updates/update_archive.gz";
     if (!file_exists($archiveFileName) || !is_file($archiveFileName)) {
         $strErrorMessage .= str_replace("#FILE#", $archiveFileName, GetMessage("SUP_NO_TEMP_FILE")) . " [PU3021]. ";
     }
 }
 if (strlen($strErrorMessage) <= 0) {
     $temporary_updates_dir = "";
     if (!CUpdateSystem::UnGzipArchive($temporary_updates_dir, $strErrorMessage, "Y")) {
         $strErrorMessage .= GetMessage("SUP_UPD_LOAD_BREAK") . " [PU303]. ";
         CUpdateSystem::AddMessage2Log(GetMessage("SUP_UPD_LOAD_BREAK"), "PU303");