Reputation: 98906
I'm running a web site where I have full control of the server and the page content.
I'm currently serving all the pages using the UTF-8 text encoding. I'm declaring this in the HTTP Content-Type
header (text/html; charset=utf-8
), and in the HTML (<meta charset="utf-8">
).
As I understand it, user-agents should (and do) give the HTTP header precedence over the HTML tag.
Given that I'm declaring the encoding in the HTTP header, is there any point in including it in the HTML too?
Upvotes: 0
Views: 111
Reputation: 888185
Yes.
This will make sure that the page is rendered correctly for users behind broken proxies that strip or mangle the header.
Upvotes: 2