Bug fix: correct bug for APACHE 1.3

git-svn-id: https://semanticscuttle.svn.sourceforge.net/svnroot/semanticscuttle/trunk@306 b3834d28-1941-0410-a4f8-b48e95affb8f
This commit is contained in:
mensonge 2009-03-05 09:24:21 +00:00
parent f14f1024fe
commit e1455c23c1

View file

@ -47,10 +47,14 @@ define('PAGE_WATCHLIST', "watchlist");
// INSTALLATION_ID is based on directory DB and used as prefix (in session and cookie) to prevent mutual login for different installations on the same host server // INSTALLATION_ID is based on directory DB and used as prefix (in session and cookie) to prevent mutual login for different installations on the same host server
define('INSTALLATION_ID', md5($GLOBALS['dbname'].$GLOBALS['tableprefix'])); define('INSTALLATION_ID', md5($GLOBALS['dbname'].$GLOBALS['tableprefix']));
// Correct bugs with PATH_INFO (maybe for Apache 1 or CGI) -- for 1&1 host...
// Correct bug with PATH_INFO (maybe for Apache 1)
if(strlen($_SERVER["PATH_INFO"])<strlen($_SERVER["ORIG_PATH_INFO"])) { if(strlen($_SERVER["PATH_INFO"])<strlen($_SERVER["ORIG_PATH_INFO"])) {
$_SERVER["PATH_INFO"] = $_SERVER["ORIG_PATH_INFO"]; $_SERVER["PATH_INFO"] = $_SERVER["ORIG_PATH_INFO"];
} }
if(strcasecmp($_SERVER["PATH_INFO"], $_SERVER["SCRIPT_NAME "]) == 0) {
unset($_SERVER["PATH_INFO"]);
}
if(strpos($_SERVER["PATH_INFO"], '.php') !== false) {
unset($_SERVER["PATH_INFO"]);
}
?> ?>