I'm getting pretty confused about an error message I'm getting when I try to validate any simple HTML document without a meta encoding like this:
<!DOCTYPE html>
<html>
<head>
<title>Test</title>
</head>
<body>Test</body>
</html>
The W3C validator http://validator.w3.org reluctantly accepts the document as valid with just a few warnings when it is pasted into the direct input form, but when the document is uploaded or loaded by URI, validation fails with this error message
The character encoding was not declared. Proceeding using windows-1252.
There are two things I don't understand about this error:
Can someone explain these two points please? I'm pretty new to this stuff, so please bear with me.
Well, it depends on what you are using.
If you don't want the validator to guess, and use UTF-8, you can add the following line
<meta charset="UTF-8">
inside the the head element.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With