Re: [SMARTY] A warning with register_globals Off + E_ALL
| From: | Monte Ohrt | Date: | Mon, 15 Apr 2002 14:53:05 +0000 |
| Subject: | Re: [SMARTY] A warning with register_globals Off + E_ALL | ||
| References: | 1 | Groups: | php.smarty.general |
| Request: | Send a blank email to php-smarty-general+get-3732@lists.php.net to get a copy of this message | ||
I'd like to use the new PHP variables, but this limits Smarty to newer versions of PHP. (We've recently added functionality that requires PHP 4.0.6+) A workaround is to determine the version of PHP on-the-fly, but this starts getting messy.
Michal Prinke wrote:
When I turn off register_globals (to get a little bit more secure), I get a warning (having error_reporting() = E_ALL) about a nonexistent index. The warning is caused by the following line (Smarty.class.php, line 486):-- Monte Ohrt <monte@ispi.net> Director of Technology, ispi Inc.strstr($GLOBALS['QUERY_STRING'], $this->_smarty_debug_id))Because I like to keep register_globals off, I solve the problem by replacing "$GLOBALS" with "$_REQUEST" - and so, the warning disappears.