On 14/12/2011 10:12, Andrei Alexandrescu wrote:
On 12/12/11 7:46 PM, Stewart Gordon wrote:
On 06/12/2011 05:44, Andrei Alexandrescu wrote:
http://d-p-l.org

Andrei

Why does it have an HTML 4.01 doctype but then go on to use XHTML syntax???

Stewart.

I wouldn't know. What needs to be done?

Are you saying someone else put that doctype there behind your back? Or that you found it on a lot of webpages and just copied it without any clue of what it means?

Since what you've obviously learned is a mishmash of old-fashioned HTML, modern HTML and XHTML, the first step would be to learn the differences between them. This will get you started:
http://www.w3schools.com/html/html_xhtml.asp

My preference nowadays is to use XHTML Strict

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
 "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd";>

though I may still use other doctypes while maintaining sites that have been around for a long time, like XHTML Transitional

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
 "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd";>

The main difference between Strict and Transitional is that Transitional includes legacy presentational elements and attributes whereas Strict doesn't. The proper way to do things nowadays is to write the content and structure in (X)HTML and use CSS for the presentation.

But whatever I try to validate it as, there are errors.

A good plan would be to change it to XHTML 1.0 Transitional and fix the handful of validation errors that still show up. I can help you to do this. Once you've got your head around these, you could consider migrating to XHTML 1.0 Strict.

Stewart.

Reply via email to