Detect encoding and make everything UTF-8

前端 未结 24 2836
暗喜
暗喜 2020-11-22 03:03

I\'m reading out lots of texts from various RSS feeds and inserting them into my database.

Of course, there are several different character encodings used in the fee

24条回答
  •  庸人自扰
    2020-11-22 03:26

    Try without 'auto'

    That is:

    mb_detect_encoding($text)
    

    instead of:

    mb_detect_encoding($text, 'auto')
    

    More information can be found here: mb_detect_encoding

提交回复
热议问题