include_ext_php() path error

Use GitHub to post bug reports and error descriptions for phpwcms. Describe your problem detailed!
Locked
jrvoorhorst
Posts: 4
Joined: Wed 2. Jun 2004, 08:52
Location: Genemuiden - Nederland

include_ext_php() path error

Post by jrvoorhorst »

There is a sort of bug in front.func.inc.php.
In the function include_ext_php() I placed the function realpath arount PHPWCMS_ROOT. See code below.

Code:
if(!$t) {
$this_path = str_replace("\\", '/', dirname(realpath($inc_file)));
$this_path = preg_replace('/\/$/', '', $this_path);

$root_path = str_replace("\\", '/', realpath(PHPWCMS_ROOT));
$root_path = preg_replace('/\/$/', '', $root_path);

if(strpos($this_path, $root_path) === 0) $t = 1;
}

Otherwise it gave different paths for root_path and this_path.
User avatar
Oliver Georgi
Site Admin
Posts: 9945
Joined: Fri 3. Oct 2003, 22:22
Location: Dessau-Roßlau
Contact:

Post by Oliver Georgi »

OK thanks.

Oliver
Oliver Georgi | phpwcms Developer | GitHub | LinkedIn
Locked