note 110019 added to function.utf8-decode
| From: | MichaelPfister | Date: | Wed, 12 Sep 2012 13:10:09 +0000 |
| Subject: | note 110019 added to function.utf8-decode | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-190652@lists.php.net to get a copy of this message | ||
I personally prefer this method for decoding an array:
private function utf8DecodeArray(&$item, $key) {
$item = utf8_decode($item);
}
Then just call it like this within the same class:
array_walk_recursive($YOURARRAY, array(&$this, 'utf8DecodeArray'));
This will replace your array with the utf8 decoded one.
----
Server IP: 69.147.83.197
Probable Submitter: 130.92.9.57 (proxied: 130.92.8.156)
----
Manual Page -- http://www.php.net/manual/en/function.utf8-decode.php
Edit -- https://master.php.net/note/edit/110019
Del: integrated -- https://master.php.net/note/delete/110019/integrated
Del: useless -- https://master.php.net/note/delete/110019/useless
Del: bad code -- https://master.php.net/note/delete/110019/bad+code
Del: spam -- https://master.php.net/note/delete/110019/spam
Del: non-english -- https://master.php.net/note/delete/110019/non-english
Del: in docs -- https://master.php.net/note/delete/110019/in+docs
Del: other reasons-- https://master.php.net/note/delete/110019
Reject -- https://master.php.net/note/reject/110019
Search -- https://master.php.net/manage/user-notes.php