the Future of the Web
  • Home
  • Hire Us
  • Articles
  • About
  • Contact
  • This site is valid XHTML 1.1

    Apr 21 2005

    That's right, I've updated this site so it is now valid XHTML 1.1. It was previously XHTML 1.0 Strict. So what did I have to change?

    1. I changed the DOCTYPE tag to:
      <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
      "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
    2. I had to remove the "lang" attribute from the <html> tag. Now, only the xml:lang attribute is allowed.

    That's it! Not too bad at all. I was also looking at what's coming in XHTML 2.0. I really like what I see. The downside is that XHTML 2.0 will not be backwards-compatible. The upside is, from what I can tell, it won't be very difficult to port an XHTML 1.x page to XHTML 2.0.

    It looks like most web pages will only need to worry about a few things like the elimination of the <img> tag (this won't matter to those using CSS to add images), and the replacement of h1-h6 tags with a single <h> tag. However, it seems that pages with lots of JavaScript forms will need to have a major rework: HTML forms are replaced with XForms, JavaScript Events with XML Events. I guess we'll need to wait and see what the final specification has to say.

    Tags: html xhtml valid doctype
    View 2 Comments | Add a comment
  • Comments

    1. SLV Dweller at 11:48pm on February 25, 2007

    I'll mention that changing the DOCTYPE and the xml:lang attribute are not the only two things needed to turn your site into a valid XHTML 1.1 site. The most important thing that's needed is to serve the site with the MIME type of application/xhtml+xml. Running this page on the validator URL below, it seems you're actually serving this page as text/html, and the DOCTYPE is actually set for XHTML 1.0 Strict. I haven't read any other entries on your site, so maybe this is just as you designed it.

    http://validator.w3.org/check?uri=http%3A%2F%2Fwww.thefutureoftheweb.com%2Fblog%2F2005%2F4%2Fthis-site-is-valid-xhtml-1-1&charset=%28detect+automatically%29&doctype=Inline&verbose=1

    2. h-christian at 6:30pm on July 17, 2007

    wow great! it's also valid xml too via Microsoft MSXML. many xhtml 1.1 valid pages i've look around is not valid msxml validation

    greeting from indonesia

    Add a Comment

    Note: HTML tags and entities will be converted so that they are displayed as you type them. This means if you type in <em>, people will see <em>, and if you type &lt;em&gt;, people will see &lt;em&gt;.

  • Request a Quote

  • Jesse Skinner

    Jesse Skinner
    • Hire Me
    • About Me
    • Email Me
    • RSS Feed RSS Icon
  • Recent Articles

    • Parse Accept-Language to detect a user's language
    • Twitter
    • Three years of The Future of the Web
    • Saving data to a file with PHP
    • Easy web scraping with PHP
    • See all the articles
    • IBM: Where and when to use Ajax
    • Code Igniter 1.6.0 Released
    • Update a Dev Site Automatically with Subversion
    • JavaScript Functions are Variables
    • See All...
  • Categories

    • javascript (37)
    • links (19)
    • about (18)
    • web (14)
    • server (10)
    • html (10)
    • css (8)
    • carnival (7)
    • browsers (7)
    • design (4)
    • seo (4)
    • ads (4)
    • standards (4)
    • events (4)
    • work (4)
  • Older Articles

    • May 2008
    • April 2008
    • February 2008
    • January 2008
    • December 2007
    • November 2007
    • September 2007
    • August 2007
    • July 2007
    • June 2007
    • May 2007
    • April 2007
    • March 2007
    • February 2007
    • January 2007
    • December 2006
    • November 2006
    • October 2006
    • September 2006
    • August 2006
    • July 2006
    • June 2006
    • May 2006
    • April 2006
    • March 2006
    • February 2006
    • January 2006
    • December 2005
    • November 2005
    • October 2005
    • September 2005
    • August 2005
    • April 2005
    • See All...
Copyright © 2008 Jesse Skinner | CSS | XHTML | RSS | Help | Impressum | Cutie Quilts | Internet Blog Top Sites