1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-07-30 21:40:43 +02:00

This is an attempt to remove problems with "file_exists()" calls in later

versions of PHP.  From what I can tell, PHP requires a full path to
file_exists() in newer versions, and realpath() will fix it.  I noticed that
file_exists() doesn't need to have a full path passed to it in older versions,
so I just made a fake function, realpath() that will only define itself
if realpath() isn't defined. It may or may not work, it seems to work here
on PHP 4.2.3, but if it breaks older versions, please *LET ME KNOW* or
change it. Because I changed this so quickly, I don't know if everything works
exactly. Really, PM or email me if it doesn't.  Cross your fingers! :D

Thanks!
dougk_ff7
dougk_ff7@phpbb.com


git-svn-id: file:///svn/phpbb/branches/phpBB-2_0_0@2935 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
dougk_ff7
2002-10-06 00:47:46 +00:00
parent a3d3c7c74f
commit 6913351af7
8 changed files with 37 additions and 21 deletions

View File

@@ -237,7 +237,7 @@ $server_port = ( !empty($HTTP_POST_VARS['server_port']) ) ? $HTTP_POST_VARS['ser
$board_email = ( !empty($HTTP_POST_VARS['board_email']) ) ? $HTTP_POST_VARS['board_email'] : "";
$script_path = ( !empty($HTTP_POST_VARS['script_path']) ) ? $HTTP_POST_VARS['script_path'] : "";
if( @file_exists('config.'.$phpEx) )
if( @file_exists(@realpath('config.'.$phpEx)) )
{
include('config.'.$phpEx);
}