Skip to content

Commit

Permalink
Fixed some errors during the upgrade/migration
Browse files Browse the repository at this point in the history
  • Loading branch information
mystralkk committed Dec 1, 2016
1 parent 24b7058 commit e9a3f91
Show file tree
Hide file tree
Showing 5 changed files with 81 additions and 98 deletions.
17 changes: 6 additions & 11 deletions public_html/admin/install/bigdump.php
Expand Up @@ -157,7 +157,7 @@

// Single file mode
if (!$error && !isset($_REQUEST["fn"]) && $filename != "") {
echo '<p><a href="' . $_SERVER['PHP_SELF'] . '?start=1&amp;fn=' . urlencode($filename) . '&amp;foffset=0&amp;totalqueries=0\">' . $LANG_BIGDUMP[0] . '</a>' . $LANG_BIGDUMP[1] . $filename . $LANG_BIGDUMP[2] . $db_name . $LANG_BIGDUMP[3] . $db_server . PHP_EOL;
echo '<p><a href="' . $_SERVER['PHP_SELF'] . '?start=1&fn=' . urlencode($filename) . '&foffset=0&totalqueries=0\">' . $LANG_BIGDUMP[0] . '</a>' . $LANG_BIGDUMP[1] . $filename . $LANG_BIGDUMP[2] . $db_name . $LANG_BIGDUMP[3] . $db_server . PHP_EOL;
}

// Open the file
Expand Down Expand Up @@ -400,9 +400,9 @@
/*** Go back to Geeklog installer ***/
echo("<script language=\"JavaScript\" type=\"text/javascript\">window.setTimeout('location.href=\""
. 'index.php?mode=migrate&step=4'
. '&language=' . $installer->getLanguage()
. '&site_url=' . $_REQUEST['site_url']
. '&site_admin_url=' . $_REQUEST['site_admin_url'] . "\";',3000);</script>\n");
. '&language=' . urlencode($installer->getLanguage())
. '&site_url=' . urlencode($_REQUEST['site_url'])
. '&site_admin_url=' . urlencode($_REQUEST['site_admin_url']) . "\";',3000);</script>\n");
} else {
if ($delayPerSession != 0) {
echo '<p><b>' . $LANG_BIGDUMP[24] . $delayPerSession . $LANG_BIGDUMP[25] . PHP_EOL;
Expand All @@ -413,9 +413,9 @@
. $_SERVER['PHP_SELF'] . '?start=' . $lineNumber . '&fn='
. urlencode($currentFileName) . '&foffset=' . $fOffset . '&totalqueries=' . $totalQueries . '&db_connection_charset=' . $db_connection_charset . '&language=' . $installer->getLanguage() . '&site_url=' . $site_url . '&site_admin_url=' . $site_admin_url . '";\',500+' . $delayPerSession . ');</script>' . PHP_EOL
. '<noscript>' . PHP_EOL
. ' <p><a href="' . $_SERVER['PHP_SELF'] . '?start=' . $lineNumber . '&amp;fn=' . urlencode($currentFileName) . '&amp;foffset=' . $fOffset . '&amp;totalqueries=' . $totalQueries . '&amp;db_connection_charset=' . $db_connection_charset . '&amp;language=' . $installer->getLanguage() . '&amp;site_url=' . $site_url . '&amp;site_admin_url=' . $site_admin_url . '">Continue from the line ' . $lineNumber . '</a></p>' . PHP_EOL
. ' <p><a href="' . $_SERVER['PHP_SELF'] . '?start=' . $lineNumber . '&fn=' . urlencode($currentFileName) . '&foffset=' . $fOffset . '&totalqueries=' . $totalQueries . '&db_connection_charset=' . $db_connection_charset . '&language=' . $installer->getLanguage() . '&site_url=' . $site_url . '&site_admin_url=' . $site_admin_url . '">Continue from the line ' . $lineNumber . '</a></p>' . PHP_EOL
. '</noscript>' . PHP_EOL
. '<p><b><a href="' . $_SERVER['PHP_SELF'] . '">' . $LANG_BIGDUMP[26] . '</a></b> ' . $LANG_BIGDUMP[27] . ' <b>' . $LANG_BIGDUMP[28] . '</b></p>' . PHP_EOL;
. '<p><strong><a href="' . $_SERVER['PHP_SELF'] . '">' . $LANG_BIGDUMP[26] . '</a></strong> ' . $LANG_BIGDUMP[27] . ' <strong>' . $LANG_BIGDUMP[28] . '</strong></p>' . PHP_EOL;
}
} else {
echo $installer->getAlertMsg($LANG_BIGDUMP[29]);
Expand All @@ -435,11 +435,6 @@
. $LANG_BIGDUMP[31] . '</p>' . PHP_EOL;
}

if ($dbConnection) {
Geeklog\Db::disconnect();
$dbConnection = null;
}

if ($file && !$gzipMode) {
fclose($file);
} elseif ($file && $gzipMode) {
Expand Down
16 changes: 0 additions & 16 deletions public_html/admin/install/classes/db.class.php
Expand Up @@ -104,22 +104,6 @@ public final static function connect($type, array $args)
return $retval;
}

/**
* Close database connection
*
* @return void
*/
abstract public function close();

/**
* Disconnect from database
*/
public static function disconnect()
{
self::$engine->close();
self::$engine = null;
}

/**
* Perform a query
*
Expand Down

0 comments on commit e9a3f91

Please sign in to comment.