Re: [SMARTY] Smarty 'unescape' variable modifier ?
| From: | Monte Ohrt | Date: | Wed, 24 Mar 2004 17:41:38 +0000 |
| Subject: | Re: [SMARTY] Smarty 'unescape' variable modifier ? | ||
| References: | 1 | Groups: | php.smarty.general |
| Request: | Send a blank email to php-smarty-general+get-11177@lists.php.net to get a copy of this message | ||
It works with any php function providing:
*) Smarty security is disabled
*) The function expects the arguments in the order that Smarty hands
them off. Most simple one-parameter functions work correctly, others may
require a wrapper.
On Wed, 2004-03-24 at 11:22, Kelly Hallman wrote:
> Mar 24 at 5:30pm, Artur Pydo wrote:
> > Artur Pydo wrote:
> > > I would like to display them and was looking for a
> > > 'unescape' modifier in Smarty.
> >
> > I had messju's and Curus answer on IRC :
> > {$var|stripslashes}
> >
> > stripslashes() is a php function but there is no need to
> > use register_modifier for php functions.
>
> MAAANNNN!! Smarty never stops blowing me away.. I have read most all of
> the documentation (I thought) and was not aware of this..
>
> This works with ANY php built-in?
> Is it documented anywhere that I can read more about it?
>
> Also, I have been meaning to test this, but if I declare a function named
> Smarty_modifier_xyz() is it used as if it were a registered plugin?
>
> --
> Kelly Hallman
> // Ultrafancy