This function support utf-8 encoding
function utf8_strrev($str){
preg_match_all('/./us', $str, $ar);
return join('',array_reverse($ar[0]));
}
![]() | strrev![]()
carmel.alex at gmail.com
28-Feb-2006 04:54
This function support utf-8 encoding
tex at i18nguy dot com
23-Aug-2005 12:36
Just a correction to the previous commenter. In ISO 8859-15, the Euro is 0xA4 (164 decimal). It is a 1 byte character.
MagicalTux at FF dot st
12-May-2005 09:20
I will make Screend at hf dot webex dot com's comment more clear and understandable.
avarab at gmail dot com
07-May-2005 03:53
strrev() can be very useful in cases where it makes more sense to do something from the end of a string rather than the beginning (well duh!) such as apply certain regular expressions. Here's a small function to add commas to numbers that works in such a way.
Screend at hf dot webex dot com
31-Mar-2004 12:17
this function can only reverse the 1-byte words,like english,it seems,using | ![]() |