can someone help me with this problem?
I've used file_get_contents() to get all text from a file
the file has the word Reparaç on it
strpos() is unable to find Reparaç
if i look for Repara it finds it so the problem is with the ç
if i echo the file_get_contents()开发者_JAVA百科 the ç appears normally
if i write the file_get_contents() information to another file a strange symbol appears instead of the ç
i'm really tired of doing stuff and searching around to try to fix this and it's probably something easy that people that are used to do php code are pretty used to dealing with but i can't figure out what's wrong with this
by the way, in many websites that i saw it seemed that the charset could be relevant for problems of this kind, i'm using UTF-8
Try to use mb_strpos()
Use mb_strpos()
instead, which is multibyte aware - strpos is for oldschool ASCII and will barf on Unicode strings.
精彩评论