How it is blowing up on our FreeBSD production server.
Unix doesn't like the:
PHP Code:
include("./global.php");
So change that to:
PHP Code:
include("global.php");
Here is the complete script, works in Win32 an Unix.
PHP Code:
// **** This little bit is because we have a directory structure, and need to include things... ****
$intDirPos = strpos($SCRIPT_NAME,"/",1);
$strDirectoryCurrent = substr($SCRIPT_NAME, 1, strpos($SCRIPT_NAME,"/",1)-1);
if($intDirPos!==false)
{ // we are calling from a sub directory
chdir("../forums");
include("global.php");
chdir("../".$strDirectoryCurrent);
}else{ // we are calling from the web root directory
chdir("./forums");
include("global.php");
chdir("..");
}