I have a wordpress web site.
I've created simple page template like:
<?php
/**
* Template Name: Test
*/
echo strlen('Привет');
?>
Then i've created a page using this template. The page shows the length of russian string 'Привет' (means 'Hello'). I expect to see 12, as UTF-8 encoded russian string consisting of 6 characters should have a size of 12 bytes, but i get 6 instead.
I've tested the same thing on other server and had correct value - 12. So i think the reason is my server configuration. I have wp 3.2.1 (i had the same problem after upgrading to wp 3.5.1) and PHP 5.3.3.
Currently i've spent about 5 days trying to find a solution, but have no luck. Does anyone know what is the reason of such behavior?
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…