Re: [SMARTY-DEV] possible _get_php_resource bug
| From: | Monte Ohrt | Date: | Sun, 16 Feb 2003 19:43:59 +0000 |
| Subject: | Re: [SMARTY-DEV] possible _get_php_resource bug | ||
| References: | 1 | Groups: | php.smarty.dev |
| Request: | Send a blank email to php-smarty-dev+get-704@lists.php.net to get a copy of this message | ||
$template_source is now defined.
On Sat, 2003-02-15 at 23:09, Greg Beaver wrote:
> Hi,
>
> While typing in phpdoc comments, I noticed that Smarty::_get_php_resource()
> refers to a variable "$template_source" that is never defined. This will at
> least cause a notice with E_ALL, and is probably a bug. The bug will only
> be triggered by a non-standard resource:
>
> } else if ($resource_type != 'file') {
> $readable = true;
> $resource_func =
> $this->_plugins['resource'][$resource_type][0][0];
> $readable = $resource_func($resource_name, $template_source,
> $this);
> }
>
> and at the function end:
>
> if ($resource_type == 'file') {
> $php_resource = $resource_name;
> } else {
> $php_resource = $template_source;
> }
>
>
> Take care,
> Greg
> --
> phpDocumentor
> http://www.phpdoc.org
--
Monte Ohrt <monte@ispi.net>