fixed wrong path when XE is installed in web root

git-svn-id: http://xe-core.googlecode.com/svn/branches/1.5.0@9050 201d5d3c-b55e-5fd7-737f-ddc643e51545
This commit is contained in:
flyskyko 2011-09-06 07:00:50 +00:00
parent dfb5d0e997
commit b8a597e219

View file

@ -221,7 +221,14 @@
if(strpos($path, './') === 0)
{
$path = dirname($_SERVER['SCRIPT_NAME']) . '/' . substr($path, 2);
if (dirname($_SERVER['SCRIPT_NAME']) == '/')
{
$path = '/' . substr($path, 2);
}
else
{
$path = dirname($_SERVER['SCRIPT_NAME']) . '/' . substr($path, 2);
}
}
else if(strpos($file, '../') === 0)
{