PEAR is archived and read-only

This mirror preserves historical PEAR package releases and metadata so existing references remain available.

Home » HTML » HTML_Template_Xipe » Bug #2770

Error finding compileDir if class used via cli

Details

Submitted2004-11-16 18:50 UTC
Fromcontact at livenet dot it
StatusSuspended
PackageHTML_Template_Xipe
PHP VersionIrrelevant
OSIrrelevant
Roadmaps(Not assigned)

Comments

[2004-11-16 18:50 UTC] contact at livenet dot it

Description:
------------
At row 306 of Main.php,

if( strpos( $this->getOption('compileDir') , $_SERVER['DOCUMENT_ROOT'] )!==0 )

needs to be

if( !empty($_SERVER['DOCUMENT_ROOT']) and strpos( $this->getOption('compileDir') , $_SERVER['DOCUMENT_ROOT'] )!==0 )

otherwise, using class out of a webserver, php raise a warning
PHP Warning: strpos(): Empty delimiter. in /var/www/libexec/pear/HTML/Template/Xipe/Main.php on line 308

and it's impossible to find compileDir.