diff options
author | Rick Ellis <rick.ellis@ellislab.com> | 2007-06-09 03:00:06 +0200 |
---|---|---|
committer | Rick Ellis <rick.ellis@ellislab.com> | 2007-06-09 03:00:06 +0200 |
commit | 09066a4b6421757e8abf76f1d48bdf252bd97e87 (patch) | |
tree | 9fb37c4be3198817697d85999f21b28b26017eb0 /index.php | |
parent | 1f852630d606e6bfd7b28dd5f599a29c437d81e8 (diff) |
Diffstat (limited to 'index.php')
-rw-r--r-- | index.php | 14 |
1 files changed, 12 insertions, 2 deletions
@@ -58,11 +58,21 @@ | | Let's attempt to determine the full-server path to the "system" | folder in order to reduce the possibility of path problems. +| Note: We only attempt this if the user hasn't specified a +| full server path. | */ -if (function_exists('realpath') AND @realpath(dirname(__FILE__)) !== FALSE) +if (strpos($system_folder, '/') === FALSE) { - $system_folder = str_replace("\\", "/", realpath(dirname(__FILE__))).'/'.$system_folder; + if (function_exists('realpath') AND @realpath(dirname(__FILE__)) !== FALSE) + { + $system_folder = realpath(dirname(__FILE__)).'/'.$system_folder; + } +} +else +{ + // Swap directory separators to Unix style for consistency + $system_folder = str_replace("\\", "/", $system_folder); } /* |