Encode/Decode an ISO-8859-1 string to UTF-8
| Published on 8/17/2008 by Dotnetindex More articles in PHP
|
PHP can encode or decode any string easily. utf8_encode function encodes the string data to UTF-8, and returns the encoded version. In other hand utf8_decode converts a string with ISO-8859-1 characters encoded with UTF-8 to single-byte ISO-8859-1.
string utf8_encode ( string $data ) Returns the UTF-8 translation of data. Data must be an ISO-8859-1 stringstring utf8_decode ( string $data )
This function decodes data , assumed to be UTF-8 encoded, to ISO-8859-1. This function decodes data , assumed to be UTF-8 encoded, to ISO-8859-1. Datamust be an UTF-8 encoded string. |
no comments submitted
Latest Posts
- Image manipulation and watermarking in PHP with GD2
- Making A Cool Login System With PHP, MySQL & jQuery
- Build a customizable RSS feed aggregator in PHP
- Custom RSS 2.0 Content Feeds using OOP
- PHP Development: Getting Started
- How to Count all elements in an array
- Making A Cool Login System With PHP, MySQL & jQuery
- Screen capture with PHP and GD
- Database driven web counter with PHP/mySQL



