Re: [SMARTY] Object-handling problem with 2.4.1
| From: | Monte Ohrt | Date: | Mon, 10 Feb 2003 21:07:02 +0000 |
| Subject: | Re: [SMARTY] Object-handling problem with 2.4.1 | ||
| References: | 1 | Groups: | php.smarty.general |
| Request: | Send a blank email to php-smarty-general+get-7628@lists.php.net to get a copy of this message | ||
A patch is committed to CVS to support dynamic method names:
$foo->$bar
by nature of the regex beast, any valid variable should compile:
$foo->$bar[0].blah.$foo->$blah <-- tested, worked!
Please give that a try.
Monte
On Mon, 2003-02-10 at 07:58, Mischa Schindowski wrote:
> Hi
>
> I\'ve a little problem with the new version 2.4.1.
>
> Code
> description:
>
> I\'ve an array with a few values and need this to \"walk\"
> through an
> object. example:
>
> $arr = array(\"foo\",\"bar\")
>
> in the
> smarty-template i\'ve to do this:
>
> {foreach from=$arr item=entry}
>
> {$object->$entry}
> {/foreach}
>
>
> in smarty-version 2.3.1 it worked well
> for me. is there a solution to work
> with the new version 2.4.1?
>
>
> Greetings and thanks a lot
>
>
> Mischa
--
Monte Ohrt <monte@ispi.net>