★ wanayoo — archive 1999 http://www.php.net/manual/hu/function.utf8-encode.phpNouvelle recherche | Portail wanayoo

PHP Home Page

Manual Table of Contents
Up to XML
Quick Reference
English version of this pageGerman version of this pageJapanese version of this pageItalian version of this pageFrench version of this page
XML
* xml_parser_create
* xml_set_object
* xml_set_element_handler
* xml_set_character_data_handler
* xml_set_processing_instruction_handler
* xml_set_default_handler
* xml_set_unparsed_entity_decl_handler
* xml_set_notation_decl_handler
* xml_set_external_entity_ref_handler
* xml_parse
* xml_get_error_code
* xml_error_string
* xml_get_current_line_number
* xml_get_current_column_number
* xml_get_current_byte_index
* xml_parser_free
* xml_parser_set_option
* xml_parser_get_option
* utf8_decode
* utf8_encode
Manual: utf8_encode
View the source code for this pageSearch the site



Previous page
 utf8_decode
 Updated
Sat, 12 Aug 2000
YAZ 
Next page


utf8_encode

(PHP3 >= 3.0.6, PHP4 )

utf8_encode -- encodes an ISO-8859-1 string to UTF-8

Description

string utf8_encode (string data)

This function encodes the string data to UTF-8, and returns the encoded version. UTF-8 is a standard mechanism used by Unicodefor encoding wide character values into a byte stream. UTF-8 is transparent to plain ASCII characters, is self-synchronized (meaning it is possible for a program to figure out where in the bytestream characters start) and can be used with normal string comparison functions for sorting and such. PHP encodes UTF-8 characters in up to four bytes, like this:

Táblázat 1. UTF-8 encoding

bytesbitsrepresentation
170bbbbbbb
211110bbbbb 10bbbbbb
3161110bbbb 10bbbbbb 10bbbbbb
42111110bbb 10bbbbbb 10bbbbbb 10bbbbbb
Each b represents a bit that can be used to store character data.


 About Notes


Previous page
 utf8_decode
 Updated
Sat, 12 Aug 2000
YAZ 
Next page





Who's responsible for this?
Top of this page

Site
Hosting:



Located in
United States
Elements of this website are subject to copyright.
Questions about installing or using PHP should be directed to one of the mailing lists.
Only questions about the website should be directed to webmaster@php.net.