Re: New htmlentities() '$double_enocde' Param Question

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 6/17/07, Chris <chris@xxxxxxxxxxxxxxxxx> wrote:
I just need a clarification about the new "$double_encode" param for
htmlentities() and htmlspecialchars().

Is it supposed to do as I expect it to do in the code below or am I
misuderstanding its use?

// Output: &lt;
echo htmlentities('<', ENT_QUOTES, false);

// Expected Output: &lt;
// Actual Output: &amp;lt;
echo htmlentities(htmlentities('<', ENT_QUOTES, false), ENT_QUOTES,
false);


Your false value for your htmlentities() call should be the 4th
parameter, not the 3rd.


--
Greg Donald
http://destiney.com/

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux