encoding issue

后端 未结 4 1434
孤街浪徒
孤街浪徒 2021-01-04 23:22

I\'m developing a website using PHP and these strange chars \"\" appears in my page, right on the top of it. My code is this:



        
相关标签:
4条回答
  • 2021-01-04 23:53

    If you want to use iso-8859-1, you need to save your PHP file as iso-8859-1.
    For detailed instructions, please tell us which editor you're using.

    However, I highly recommend that you use UTF8 instead.

    0 讨论(0)
  • 2021-01-05 00:00

    That's a BOM character, which is there because the source code files are saved as UTF-8 BOM. Try to save them as UTF-8 no-BOM (or whatever your editor calls it) or indeed ISO-8859-1 if you must use it (...why would you?).

    0 讨论(0)
  • 2021-01-05 00:00

    Look at the "Page Info" screen and see what character set the browser thinks you're in. The odds are that your web server is forcing UTF-8 with its Content-Type header, which trumps the meta tag.

    0 讨论(0)
  • 2021-01-05 00:06

    simple solution, just placed your html/php code is start from first line, I am just do that to resolve these problem, and it's work.

    0 讨论(0)
提交回复
热议问题