array ( 0 => 'index.php', 1 => 'PHP Manual', ), 'head' => array ( 0 => 'UTF-8', 1 => 'en', ), 'this' => array ( 0 => 'function.iconv-get-encoding.php', 1 => 'iconv_get_encoding', ), 'up' => array ( 0 => 'ref.iconv.php', 1 => 'iconv Functions', ), 'prev' => array ( 0 => 'ref.iconv.php', 1 => 'iconv Functions', ), 'next' => array ( 0 => 'function.iconv-mime-decode-headers.php', 1 => 'iconv_mime_decode_headers', ), 'alternatives' => array ( ), 'source' => array ( 'lang' => 'en', 'path' => 'reference/iconv/functions/iconv-get-encoding.xml', ), ); $setup["toc"] = $TOC; $setup["toc_deprecated"] = $TOC_DEPRECATED; $setup["parents"] = $PARENTS; manual_setup($setup); ?>
(PHP 4 >= 4.0.5, PHP 5, PHP 7, PHP 8)
iconv_get_encoding — Retrieve internal configuration variables of iconv extension
Retrieve internal configuration variables of iconv extension.
type
The value of the optional type
can be:
Returns the current value of the internal configuration variable if
successful or false
on failure.
If type
is omitted or set to "all",
iconv_get_encoding() returns an array that
stores all these variables.
Example #1 iconv_get_encoding() example
<pre>
<?php
iconv_set_encoding("internal_encoding", "UTF-8");
iconv_set_encoding("output_encoding", "ISO-8859-1");
var_dump(iconv_get_encoding('all'));
?>
</pre>
The above example will output:
Array ( [input_encoding] => ISO-8859-1 [output_encoding] => ISO-8859-1 [internal_encoding] => UTF-8 )