Posted by Jonathan N. Little on 09/27/97 11:52
Rik wrote:
> Jonathan N. Little wrote:
>> You sure that will not cause a second evaluation of htmlentities?
>
> Quite, not a 100%, but highly probable. A small test:
>
> <?php
> $i = 0;
> function check($string){
> global $i;
> $i++;
> return $string;
> }
> printf('%1$s %1$s %1$s',check('<br />We\'ll see'));
> echo $i;
>
> echo check('<br />and now:');
> echo $i;
> ?>
>
> Returns:
> We'll see
> We'll see
> We'll see1
> and now:2
>
> $i = 1, evaluated one time only.
>
'nuf for me! Log that baby for future use!
--
Take care,
Jonathan
-------------------
LITTLE WORKS STUDIO
http://www.LittleWorksStudio.com
[Back to original message]
|