mirror of
https://github.com/ezyang/htmlpurifier.git
synced 2025-01-05 06:01:52 +00:00
Add UTF-8 encoding declaration to htmlspecialchars.
git-svn-id: http://htmlpurifier.org/svnroot/htmlpurifier/trunk@251 48356398-32a2-884e-a903-53898d9a118a
This commit is contained in:
parent
8c1a4c63ba
commit
ebf0da9b78
@ -33,7 +33,7 @@ echo $pure_html;
|
|||||||
<p>Here is the source code of the purified HTML:</p>
|
<p>Here is the source code of the purified HTML:</p>
|
||||||
<pre><?php
|
<pre><?php
|
||||||
|
|
||||||
echo htmlspecialchars($pure_html);
|
echo htmlspecialchars($pure_html, ENT_COMPAT, 'UTF-8');
|
||||||
|
|
||||||
?></pre>
|
?></pre>
|
||||||
<?php
|
<?php
|
||||||
@ -53,7 +53,7 @@ will filter it.</p>
|
|||||||
<legend>HTML</legend>
|
<legend>HTML</legend>
|
||||||
<textarea name="html" cols="60" rows="15"><?php
|
<textarea name="html" cols="60" rows="15"><?php
|
||||||
|
|
||||||
if (isset($html)) echo htmlspecialchars($html);
|
if (isset($html)) echo htmlspecialchars($html, ENT_COMPAT, 'UTF-8');
|
||||||
|
|
||||||
?></textarea>
|
?></textarea>
|
||||||
<div>
|
<div>
|
||||||
|
Loading…
Reference in New Issue
Block a user