mirror of
https://github.com/sigmasternchen/php-doc-en
synced 2025-03-16 00:48:54 +00:00
fix for bug #21592, list of supported charsets added
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@118785 c90b9560-bf6c-de11-be94-00142212c4b1
This commit is contained in:
parent
2045db5a32
commit
6773d9e51a
3 changed files with 18 additions and 12 deletions
|
@ -1,5 +1,5 @@
|
|||
<?xml version="1.0" encoding="iso-8859-1"?>
|
||||
<!-- $Revision: 1.3 $ -->
|
||||
<!-- $Revision: 1.4 $ -->
|
||||
<!-- splitted from ./en/functions/strings.xml, last change in rev 1.2 -->
|
||||
<refentry id="function.html-entity-decode">
|
||||
<refnamediv>
|
||||
|
@ -54,9 +54,10 @@
|
|||
</para>
|
||||
<para>
|
||||
The ISO-8859-1 character set is used as default for the optional third
|
||||
<parameter>charset</parameter>. This defines the character set used in
|
||||
conversion.
|
||||
<parameter>charset</parameter>. This defines the character set used in
|
||||
conversion. Support for this third argument was added in PHP 4.1.0.
|
||||
</para>
|
||||
&reference.strings.charsets;
|
||||
<para>
|
||||
<example>
|
||||
<title>Decoding html entities</title>
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
<?xml version="1.0" encoding="iso-8859-1"?>
|
||||
<!-- $Revision: 1.8 $ -->
|
||||
<!-- $Revision: 1.9 $ -->
|
||||
<!-- splitted from ./en/functions/strings.xml, last change in rev 1.2 -->
|
||||
<refentry id="function.htmlentities">
|
||||
<refnamediv>
|
||||
|
@ -54,15 +54,16 @@
|
|||
</table>
|
||||
</para>
|
||||
<para>
|
||||
Support for the optional <parameter>quote</parameter> parameter was
|
||||
Support for the optional <parameter>quote</parameter> parameter was
|
||||
added in PHP 4.0.3.
|
||||
</para>
|
||||
<para>
|
||||
Like <function>htmlspecialchars</function>, it takes an optional
|
||||
third argument which defines character set used in conversion.
|
||||
Support for this argument was added in PHP 4.1.0. Presently, the
|
||||
ISO-8859-1 character set is used as the default.
|
||||
third argument <parameter>charset</parameter> which defines character
|
||||
set used in conversion. Support for this argument was added in PHP 4.1.0.
|
||||
Presently, the ISO-8859-1 character set is used as the default.
|
||||
</para>
|
||||
&reference.strings.charsets;
|
||||
<para>
|
||||
If you're wanting to decode instead (the reverse) you can use
|
||||
<function>html_entity_decode</function>.
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
<?xml version="1.0" encoding="iso-8859-1"?>
|
||||
<!-- $Revision: 1.5 $ -->
|
||||
<!-- $Revision: 1.6 $ -->
|
||||
<!-- splitted from ./en/functions/strings.xml, last change in rev 1.2 -->
|
||||
<refentry id="function.htmlspecialchars">
|
||||
<refnamediv>
|
||||
|
@ -71,7 +71,10 @@
|
|||
<title><function>htmlspecialchars</function> example</title>
|
||||
<programlisting role="php">
|
||||
<![CDATA[
|
||||
<?php
|
||||
$new = htmlspecialchars("<a href='test'>Test</a>", ENT_QUOTES);
|
||||
echo $new; // <a href='test'>Test</a>
|
||||
?>
|
||||
]]>
|
||||
</programlisting>
|
||||
</example>
|
||||
|
@ -83,10 +86,11 @@ $new = htmlspecialchars("<a href='test'>Test</a>", ENT_QUOTES);
|
|||
second argument was added in PHP 3.0.17 and PHP 4.0.3.
|
||||
</para>
|
||||
<para>
|
||||
The third argument defines character set used in conversion. The
|
||||
default character set is ISO-8859-1. Support for this third argument was
|
||||
added in PHP 4.1.0.
|
||||
The third argument <parameter>charset</parameter> defines character set
|
||||
used in conversion. The default character set is ISO-8859-1. Support for
|
||||
this third argument was added in PHP 4.1.0.
|
||||
</para>
|
||||
&reference.strings.charsets;
|
||||
<para>
|
||||
See also <function>get_html_translation_table</function>,
|
||||
<function>htmlentities</function>, and <function>nl2br</function>.
|
||||
|
|
Loading…
Reference in a new issue