Hire Me

XHTML

XHTML

Some XHTML

XHTML stands for eXtensible HyperText Markup Language. It is an extension of HTML but based on XML rather than SGML which means it must be 'well-formed'. XHTML is pretty much the de-facto standard for coding web pages these days and its requirement to be well-formed has helped drive forward advancements and awareness of the importance of accessibility and usability.

Hand Code XHTML

I am fluent in XHTML and always hand-code everything - I find it gives me the most control over my pages and results in much cleaner code than if I relied on a WYSIWYG editor. Also coding a page from scratch and understanding every element of the code makes it much easier to debug the inevitable cross-browser compatibility issues (thank you IE 6). I always run my pages through the W3C Validator once I'm finished, unfortunately when the client gets their hands on the CMS the validation can go out the window!

However saying that I do not believe that it is as simple as valid code = good code. If you check this site you will find it does not validate because I have used the following attribute in a form tag:

autocomplete="off"

This basically stops the browser remembering the user's input so it is typically used for credit card number fields or email confirmation fields. This attribute has a genuinely useful purpose and is supported by all the major browsers - so I am happy to use it, its about disgression and balance. I could cheat and add the attribute after tha page has loaded using Javascript which would make the page validate but only because it has tricked the validator and what would be the point of that? The page would still be invalid but at least it would appear to be valid... I think that might be missing the point!

Semantic Markup

I am a strong believer in using semantic markup. This basically means using tags for what they were intended for - if you want to add a heading to your page, use a heading tag (e.g. <h1>, <h2>...), if you want to emphasize some text use the <em> tag.

Well written, solid XHTML makes life much easier when it comes to writing the CSS or making a site work nicely on a mobile device.

I'm am hoping to learn more about HTML5 soon - it is currently in development and may become a W3C recommendation by the end of 2010.

 

Some thoughts on...

Contact Me

Sending...

Thank You

Your message has been sent - I'll be in touch ASAP

Close