Skip to content

Commit

Permalink
Separate include
Browse files Browse the repository at this point in the history
git-svn-id: https://adminer.svn.sourceforge.net/svnroot/adminer/trunk@623 7c3ca157-0c34-0410-bff1-cbf682f78f5c
  • Loading branch information
jakubvrana committed May 29, 2009
1 parent 18d744a commit 041fb2e
Show file tree
Hide file tree
Showing 12 changed files with 13 additions and 13 deletions.
6 changes: 3 additions & 3 deletions _compile.php
@@ -1,5 +1,5 @@
<?php
include dirname(__FILE__) . "/version.inc.php";
include dirname(__FILE__) . "/include/version.inc.php";
include dirname(__FILE__) . "/externals/jsmin-php/jsmin.php";

function add_apo_slashes($s) {
Expand Down Expand Up @@ -52,7 +52,7 @@ function put_file($match) {
return "switch (\$LANG) {\n$return}\n";
}
$return = file_get_contents(dirname(__FILE__) . "/$match[3]");
if ($match[3] == "./lang.inc.php" && $_COOKIE["lang"] && (preg_match("~case '$_COOKIE[lang]': (.*) break;~", $return, $match2) || preg_match("~default: (.*)~", $return, $match2))) {
if ($match[3] == "./include/lang.inc.php" && $_COOKIE["lang"] && (preg_match("~case '$_COOKIE[lang]': (.*) break;~", $return, $match2) || preg_match("~default: (.*)~", $return, $match2))) {
return "$match[1]\nfunction lang(\$ar, \$number) {\n\t$match2[1]\n\treturn sprintf(\$ar[\$pos], \$number);\n}\n$match[4]";
}
$return = preg_replace("~\\?>\n?\$~", '', $return);
Expand Down Expand Up @@ -151,7 +151,7 @@ function php_shrink($input) {
error_reporting(E_ALL & ~E_NOTICE);
if ($_SERVER["argc"] > 1) {
$_COOKIE["lang"] = $_SERVER["argv"][1];
include dirname(__FILE__) . "/lang.inc.php";
include dirname(__FILE__) . "/include/lang.inc.php";
if ($_SERVER["argc"] != 2 || !isset($langs[$_COOKIE["lang"]])) {
echo "Usage: php _compile.php [lang]\nPurpose: Compile phpMinAdmin[-lang].php from index.php.\n";
exit(1);
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
20 changes: 10 additions & 10 deletions index.php
Expand Up @@ -46,17 +46,17 @@ function save_coverage() {
set_magic_quotes_runtime(false);
$SELF = preg_replace('~^[^?]*/([^?]*).*~', '\\1?', $_SERVER["REQUEST_URI"]) . (strlen($_GET["server"]) ? 'server=' . urlencode($_GET["server"]) . '&' : '') . (strlen($_GET["db"]) ? 'db=' . urlencode($_GET["db"]) . '&' : '');

include "./version.inc.php";
include "./functions.inc.php";
include "./lang.inc.php";
include "./include/version.inc.php";
include "./include/functions.inc.php";
include "./include/lang.inc.php";
include "./lang/$LANG.inc.php";
include "./pdo.inc.php";
include "./mysql.inc.php";
include "./design.inc.php";
include "./auth.inc.php";
include "./connect.inc.php";
include "./editing.inc.php";
include "./export.inc.php";
include "./include/pdo.inc.php";
include "./include/mysql.inc.php";
include "./include/design.inc.php";
include "./include/auth.inc.php";
include "./include/connect.inc.php";
include "./include/editing.inc.php";
include "./include/export.inc.php";

if (isset($_GET["download"])) {
include "./download.inc.php";
Expand Down

0 comments on commit 041fb2e

Please sign in to comment.