hno Posted August 2, 2011 Share Posted August 2, 2011 hi, I need to use strlen in my php website but the problem is strlen return different value for Arabic characters and English characters So for every Arabic character php returns 2 but in English it returns 1 . Is there anyway to separate English from Arabic?I need to know the real strlen for Both languages .How should I do that? Thanks Link to comment https://forums.phpfreaks.com/topic/243558-how-to-distinguish-arabic-character/ Share on other sites More sharing options...
btherl Posted August 2, 2011 Share Posted August 2, 2011 You can try http://php.net/manual/en/function.mb-strlen.php Make sure you specify the encoding. Link to comment https://forums.phpfreaks.com/topic/243558-how-to-distinguish-arabic-character/#findComment-1250547 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.