mirror of
https://github.com/sigmasternchen/php-doc-en
synced 2025-03-28 23:08:55 +00:00

git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@176949 c90b9560-bf6c-de11-be94-00142212c4b1
66 lines
2.2 KiB
XML
66 lines
2.2 KiB
XML
<?xml version="1.0" encoding="iso-8859-1"?>
|
|
<!-- $Revision: 1.10 $ -->
|
|
<!-- splitted from ./en/functions/iconv.xml, last change in rev 1.1 -->
|
|
<refentry id="function.iconv">
|
|
<refnamediv>
|
|
<refname>iconv</refname>
|
|
<refpurpose>Convert string to requested character encoding</refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<methodsynopsis>
|
|
<type>string</type><methodname>iconv</methodname>
|
|
<methodparam><type>string</type><parameter>in_charset</parameter></methodparam>
|
|
<methodparam><type>string</type><parameter>out_charset</parameter></methodparam>
|
|
<methodparam><type>string</type><parameter>str</parameter></methodparam>
|
|
</methodsynopsis>
|
|
<para>
|
|
Performs a character set conversion on the string
|
|
<parameter>str</parameter> from <parameter>in_charset</parameter>
|
|
to <parameter>out_charset</parameter>. Returns the converted
|
|
string or &false; on failure.
|
|
</para>
|
|
<para>If you append the string <literal>//TRANSLIT</literal> to
|
|
<parameter>out_charset</parameter> transliteration is activated. This
|
|
means that when a character can't be represented in the target charset,
|
|
it can be approximated through one or several similarly looking
|
|
characters. If you append the string <literal>//IGNORE</literal>,
|
|
characters that cannot be represented in the target charset are silently
|
|
discarded. Otherwise, <parameter>str</parameter> is cut from the first
|
|
illegal character.
|
|
</para>
|
|
<para>
|
|
<example>
|
|
<title><function>iconv</function> example:</title>
|
|
<programlisting role="php">
|
|
<![CDATA[
|
|
<?php
|
|
echo iconv("ISO-8859-1", "UTF-8", "This is a test.");
|
|
?>
|
|
]]>
|
|
</programlisting>
|
|
</example>
|
|
</para>
|
|
</refsect1>
|
|
</refentry>
|
|
|
|
<!-- Keep this comment at the end of the file
|
|
Local variables:
|
|
mode: sgml
|
|
sgml-omittag:t
|
|
sgml-shorttag:t
|
|
sgml-minimize-attributes:nil
|
|
sgml-always-quote-attributes:t
|
|
sgml-indent-step:1
|
|
sgml-indent-data:t
|
|
indent-tabs-mode:nil
|
|
sgml-parent-document:nil
|
|
sgml-default-dtd-file:"../../../../manual.ced"
|
|
sgml-exposed-tags:nil
|
|
sgml-local-catalogs:nil
|
|
sgml-local-ecat-files:nil
|
|
End:
|
|
vim600: syn=xml fen fdm=syntax fdl=2 si
|
|
vim: et tw=78 syn=sgml
|
|
vi: ts=1 sw=1
|
|
-->
|