Why do symbols like apostrophes and hyphens get replaced with black diamonds on my website?

前端 未结 7 1282
暖寄归人
暖寄归人 2020-12-08 13:27

A website I\'ve made has a few problems... On one of the pages, wherever there\'s an apostrophe (\') or a dash (-), the symbol gets replaced with a

7条回答
  •  没有蜡笔的小新
    2020-12-08 14:14

    You need to change your text to 'Plain text' before pasting into the HTML document. This looks like an error I've had before by pasting straight from MS word.

    MS word and other rich text editors often place hidden or invalid chars into your code. Try using for your dashes, or for apostrophes (etc), to eliminate the need for relying on your char encoding.

提交回复
热议问题