20-11-2010, 19:49
Witam. Mnie to gryzie. Używam Notepada++, kodowanie ustawione na UTF-8 bez BOM, wg zaleceń, puszczam przez walidator w3c i dostaję taki efekt:
Czy to normalne? Mam się nie przejmować i brnąć dalej? Sprawdziłem też kodowanie z BOM, wyskoczyła jedynie informacja, że starsze przeglądarki mogą mieć problemy.
Mój kod
Kod:
Tentatively passed, 2 warning(s)
(...)
No Character Encoding Found! Falling back to UTF-8.
None of the standards sources gave any information on the character encoding labeling for this document. Without encoding information it is impossible to reliably validate the document. As a fallback solution, the "UTF-8" encoding was used to read the content and attempt to perform the validation, but this is likely to fail for all non-trivial documents.
Info No Character encoding declared at document level
No character encoding information was found within the document, either in an HTML meta element or an XML declaration. It is often recommended to declare the character encoding in the document itself, especially if there is a chance that the document will be read from or saved to disk, CD, etc.
Czy to normalne? Mam się nie przejmować i brnąć dalej? Sprawdziłem też kodowanie z BOM, wyskoczyła jedynie informacja, że starsze przeglądarki mogą mieć problemy.
Mój kod
Kod:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="pl" lang="pl">
<head>
<title>Tytuł ot tak</title>
<meta http-equiv="Content Type" content="text/html; charset=utf-8" />
<meta http-equiv="Content-Style-Type" content="text/css" />
<style type="text/css">
body {
margin: 100px 200px;
font-family: "Trebuchet MS", sans-serif;
background: rgb(255,251,196);
font-size: large; }
p {
margin: 100px 0px; }
#stopka {
font-size: 60%;
margin-top: 100px;
font-family: Verdana, sans-serif; }
</style>
</head>
<body>
<p>Niebanalny tekst, który przed chwilą został przeczytany.</p>
</body>
</html>