Page 1 sur 1

Problèmes avec w3 validator et xhtml

Posté : 20 mars 2005, 23:51
par QD
Salut,
J'essaie de faire un site aux normes xhtml

pour le moment mon fichier index.php contient ceci

Code : Tout sélectionner

echo "<!DOCTYPE html PUBLIC '-//W3C//DTD XHTML 1.0 Transitional//EN' 'http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd'>\n"; echo "<meta name='author' content='Didier QD QUELOZ [email protected]' />\n"; echo "<meta name='copyright' content='restonet.ch 2004' />\n"; echo "<meta http-equiv='Content-Language' content='fr' />\n"; echo "<meta http-equiv='Content-Type' content='text/html; charset=ISO-8859-1' />\n"; echo "<meta http-equiv='Content-Style-Type' content='text/css' />\n"; echo "<title>Restonet.ch</title>\n";
et sur validator ca me met ces erreurs

Code : Tout sélectionner

Line 2, column 67: document type does not allow element "meta" here ...r' content='Didier QD QUELOZ [email protected]' /> The element named above was found in a context where it is not allowed. This could mean that you have incorrectly nested elements -- such as a "style" element in the "body" section instead of inside "head" -- or two elements that overlap (which is not allowed). One common cause for this error is the use of XHTML syntax in HTML documents. Due to HTML's rules of implicitly closed elements, this error can create cascading effects. For instance, using XHTML's "self-closing" tags for "meta" and "link" in the "head" section of a HTML document may cause the parser to infer the end of the "head" section and the beginning of the "body" section (where "link" and "meta" are not allowed; hence the reported error). Line 3, column 51: document type does not allow element "meta" here <meta name='copyright' content='restonet.ch 2004' /> Line 4, column 50: document type does not allow element "meta" here <meta http-equiv='Content-Language' content='fr' /> Line 5, column 73: document type does not allow element "meta" here ...e' content='text/html; charset=ISO-8859-1' /> Line 6, column 58: document type does not allow element "meta" here <meta http-equiv='Content-Style-Type' content='text/css' /> Line 7, column 6: document type does not allow element "title" here <title>Restonet.ch</title>
Je comprends pas ce que sont mes erreurs. Qqn peut m'aider?

MErci d'avance

Posté : 21 mars 2005, 00:02
par Xenon_54
Où est ton <head>?

Posté : 21 mars 2005, 10:57
par Cyrano
Pas juste le <head>
Je ne vois pas non plus le <html>...?

Posté : 21 mars 2005, 19:21
par QD
ah ouais ok je pensais pas que qu'il fallait mettre toute toute toute les balisesgenre html head body etc now ca va mieux tout passe merci les mec