possible assign + multiple modifiers bug
| From: | N.W.M. Schoot | Date: | Tue, 18 Mar 2003 12:06:17 +0000 |
| Subject: | possible assign + multiple modifiers bug | ||
| Groups: | php.smarty.dev | ||
| Request: | Send a blank email to php-smarty-dev+get-985@lists.php.net to get a copy of this message | ||
Hi,
I'm still in the process of upgrading my 2.3.1 code to version 2.5.x and I
ran into another difference which may be a bug.
Multiple modifiers in assignments seem to go wrong:
This code works like it should:
{assign var="testing" value="Modifier test"}
{$testing|lower|spacify}
Results in:
m o d i f i e r t e s t
Which is as designed. The following code however:
{assign var="testing" value="Modifier test"}
{assign var="moretesting" value=$testing|lower|spacify}
{$moretesting}
Results in:
Modifier test|lower|spacify
Which is incorrect: in 2.3.1 both modifiers are executed. Placing quotes
around $testing|lower|spacify makes no difference. Using a single modifier
as in the line:
{assign var="moretesting" value=$testing|lower}
results in:
modifier test
(note the lowered 'M' of modifier)
So that works correctly, it seems only to go wrong when using two (or more?)
modifiers.
Regards
Niels