Jump to content

DOCTYPE?


eduard

Recommended Posts

The DTD must look EXACTLY like one of the DTDs in W3Schools' reference, and it MUST be placed at the very first line of an (X)HTML document.Those are the standard DTDs, and they should not be altered like that.Everything in the first quote pair is the so called "public identifier". It's supposed to identify the DTD in a way that would potentially let the user agent (browser) to know this is a certain version of (X)HTML even if it can't access the actual DTD file. The different parts of the string themselves don't mean anything. It's just how W3C decided to call the public identifier.As you can guess, the second quote pair points to the actual DTD file to load and validate against. It's called "system identifier".Some of today's browsers don't use the public identifier as it was intended though. They look at the whole DTD (system identifier included), and trigger the so called "standards mode" only if it's one of the standard DTDs, as shown in the reference. Otherwise, they use the so called "quirks mode" in which they defy standards in the ways developers actually coded their pages back in the day.

Link to comment
Share on other sites

If you want to put your name in a meta tag, you can see how to do it here. You will also see on that page that when a meta tag identifies an http-equiv, its value must be a valid HTTP Header Type, and the page lists several. Your name is not one of them. :)What you probably want is this tag, exactly as you see it here:<meta http-equiv="content-type" content="text/html;charset=UTF-8">

Link to comment
Share on other sites

The validator still gives an error!<meta http-equiv="eduard lid" content/html; charset=UTF-8/>The error?
If you are using W3C validator, check the "Clean up Markup with HTML Tidy" you can find in the "options" (http://validator.w3.org/#validate_by_uri+with_options).you will find your code almost perfectly corrected (sometimes you must be careful with the corrections applied but in your case I believe it will work well)gabriele
Link to comment
Share on other sites

If you want to put your name in a meta tag, you can see how to do it here. You will also see on that page that when a meta tag identifies an http-equiv, its value must be a valid HTTP Header Type, and the page lists several. Your name is not one of them. :)What you probably want is this tag, exactly as you see it here:<meta http-equiv="content-type" content="text/html;charset=UTF-8">
I made the changes, but now the validator says it cannot validate this document?<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN""http://www.w3.org/TR/html4/loose.dtd"><HTML><head><meta http-equiv="content-type" content="text/ html; charset=UTF-8"><title>Eduard Lid</title><link rel="stylesheet" type="text/css" href="ex1.css"></head><body><div class="header"><a href="http://www.eduardlid.com/book/mine.html">Libro</a><a href="http://www.viadeo.com/es/profile/eduard.lid">Perfil</a></div><div id="main"><img src="images/me.JPG" alt="Eduard Lid" align="right" width="373" height="279"></div><div class="footer"><p class="sansserif">Eduard Lid</p><h6>Este sitio web es hecho por Eduard Lid ©</h6></div></body></HTML>
Link to comment
Share on other sites

I made the changes, but now the validator says it cannot validate this document?<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN""http://www.w3.org/TR/html4/loose.dtd"><HTML><head><meta http-equiv="content-type" content="text/ html; charset=UTF-8"><title>Eduard Lid</title><link rel="stylesheet" type="text/css" href="ex1.css"></head><body><div class="header"><a href="http://www.eduardlid.com/book/mine.html">Libro</a><a href="http://www.viadeo.com/es/profile/eduard.lid">Perfil</a></div><div id="main"><img src="images/me.JPG" alt="Eduard Lid" align="right" width="373" height="279"></div><div class="footer"><p class="sansserif">Eduard Lid</p><h6>Este sitio web es hecho por Eduard Lid ©</h6></div></body></HTML>
I found the error: the copyright sign!
Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...