|
From: Jirka P. <fi...@us...> - 2002-04-15 13:19:05
|
> Of course that third argument is only in PHP >=3D 4.1.0, so if it does > work, we just made a new requirement. :( We have to make new requirement only for users using non ascii charsets. No= one is using PHP 3.x seriously now and 4.1.x is a bit buggy one. I think e= veryone is waiting for 4.2 and everyone, who is taking it seriously will us= e it. > On Mon, Apr 15, 2002 at 04:48:30AM -0700, Ben Curtis wrote: >> These two functions replace certain html characters with their character >> code equivalents. They are especially necessary when printing out a >> value that may contain a " into the value attribute of a text input box. This could be done by addslashes() function. I think there is still no need= for htmlspecialchars, because it's doing the same thing but it's formattin= g special chars badly in PHP < 4.1.0. Maybe it will work in PHP >=3D 4.1 wi= th using the third parameter. I'm using PHP vs. MySQL for a really long time and I've never needed using = htmlspecialchars for this reason before, I'm using addslashes/stripslashes = combo. >> Though I don't have much experience with other charsets, it looks like >> the functions take a charset as an optional third option. Jirka, will >> you try putting them back in using the charset from cz.php and see if it >> works? I'll try using third parameter later today and I'll report to dev list. If it will work and we decide to use it, we have to rewrite all occurences = of htmlspecialchars function. But this is only one part of problem. Second = part is templates htmlentities attribute. Is it necessary to use it? Maybe = we are using too much conversion from and back to htmlspecialchars, htmlent= ities, slashes and we are losing the goal. Maybe. I'm not sure, it's on you= r decision. Jirka |