Esempio n. 1
0
         $linkurl = 'action=' . $theurl . '&step=3';
         cpmsg('upgrade_download_complete_to_compare', $linkurl, 'loading', array('upgradeurl' => upgradeinformation(0)));
     } else {
         $downloadstatus = $discuz_upgrade->download_file($upgradeinfo, $updatefilelist[$fileseq - 1], 'upload', $updatemd5filelist[$fileseq - 1]);
         if ($downloadstatus == 1) {
             $linkurl = 'action=' . $theurl . '&step=2&fileseq=' . $fileseq;
             cpmsg('upgrade_downloading_file', $linkurl, 'loading', array('file' => $updatefilelist[$fileseq - 1], 'percent' => sprintf("%2d", 100 * $fileseq / count($updatefilelist)) . '%', 'upgradeurl' => upgradeinformation(1)));
         } elseif ($downloadstatus == 2) {
             $linkurl = 'action=' . $theurl . '&step=2&fileseq=' . ($fileseq + 1);
             cpmsg('upgrade_downloading_file', $linkurl, 'loading', array('file' => $updatefilelist[$fileseq - 1], 'percent' => sprintf("%2d", 100 * $fileseq / count($updatefilelist)) . '%', 'upgradeurl' => upgradeinformation(1)));
         } else {
             cpmsg('upgrade_redownload', 'action=' . $theurl . '&step=2&fileseq=' . $fileseq, 'form', array('file' => $updatefilelist[$fileseq - 1], 'upgradeurl' => upgradeinformation(-3)));
         }
     }
 } elseif ($step == 3) {
     list($modifylist, $showlist, $ignorelist) = $discuz_upgrade->compare_basefile($upgradeinfo, $updatefilelist);
     if (empty($modifylist) && empty($showlist) && empty($ignorelist)) {
         cpmsg('filecheck_nofound_md5file', '', 'error', array('upgradeurl' => upgradeinformation(-4)));
     }
     showtablerow('class="header"', 'colspan="2"', $lang['founder_upgrade_diff_show']);
     foreach ($updatefilelist as $v) {
         if (isset($ignorelist[$v])) {
             continue;
         } elseif (isset($modifylist[$v])) {
             showtablerow('', array('class="" style="color:red;"', 'class="td24" style="color:red;"'), array('<em class="files bold">' . $v . '</em>', $lang['founder_upgrade_diff'] . '<em class="edited">&nbsp;</em>'));
         } elseif (isset($showlist[$v])) {
             showtablerow('', array('class=""', 'class="td24"'), array('<em class="files bold">' . $v . '</em>', $lang['founder_upgrade_normal'] . '<em class="fixed">&nbsp;</em>'));
         } else {
             showtablerow('', array('class=""', 'class="td24"'), array('<em class="files bold">' . $v . '</em>', $lang['founder_upgrade_new'] . '<em class="unknown">&nbsp;</em>'));
         }
     }