search

Home  >  Q&A  >  body text

Query Chinese garbled characters?

The Chinese displayed after php queries the database becomes '? ? 'what to do? No method of searching online will work

Labmem No.000Labmem No.0002583 days ago1314

reply all(4)I'll reply

  • 小张

    小张2018-05-16 10:59:36

    You can set the encoding after connecting to the database

    $query=set names uft8;

    $result=$conn->query($query);

    reply
    1
  • Darker

    Darker2017-10-20 14:39:02

    Set the encoding format to utf8 mode first, then add <meta charset=utf-8>

    reply
    0
  • Labmem No.000

    Labmem No.0002017-10-18 19:52:50

    I found it=- =


    ##http://yanue.net/post-134.html

    reply
    0
  • Cancelreply