ID: 15097
Comment by: [EMAIL PROTECTED]
Old Reported By: [EMAIL PROTECTED]
Reported By: [EMAIL PROTECTED]
Status: Open
Bug Type: Strings related
Operating System: win2000
PHP Version: 4.1.1
New Comment:

This is not a bug. substr_count($haystack, $needle)

when haystack is "D求求" and needle is "D", it returns 3 of course,
since D is found 3 times in haystack


Previous Comments:
------------------------------------------------------------------------

[2002-01-18 06:50:52] [EMAIL PROTECTED]

View my code:
   $str1="D求求";
   $str2="D";
   print substr_count($str1,$str2); 
return 3,right result is 1
the string "求" in Gb2312,is Chinese.
Used english is right,I don't konw where the problem in it. 

------------------------------------------------------------------------



Edit this bug report at http://bugs.php.net/?id=15097&edit=1


-- 
PHP Development Mailing List <http://www.php.net/>
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to