Scott Granneman

Contact | Site Map | Search
HomeWritingPresentationsTeachingWeb DevTech InfoUseful LinksPersonal
Home > Web Dev > Coding > HTML Mistakes

Top HTML mistakes

The following were gathered from a discussion on a listserv for Web developers. The question was, "What are the most common HTML mistakes?"

Closure

Not closing <font> tags

Not closing <table>, <tr>, and <td> tags

<head>

Lack of doctype or possibly worse, use of doctype that doesn't validate

Lack of meta tags, particularly 'no-cache' on dynamic sites

Not giving your page a relevant title

Images

Not putting height and width attributes in image tags

Not filling in the alt tag

Linking

Local file references <img src='c:/mystuff/me.jpg'>

Forgetting the protocol on an external link <a href='www.foo.bar'>

Confusing relative and absolute paths

Tables

Table abuse (too much nesting or too many col/rowspans)

<td valign='center'> instead of the proper <td valign='middle'>

Spacing before a </td>

Forgetting to set all table attributes to zero when going for a seamless grid

Standards

Improperly nesting tags? Like <i><b>text</i></b>

Use of deprecated tags (font, center, etc.)

CAPITALIZING HTML TAGS

Not using "" for *all* attributes

Dropping a quote from an attribute this='that

Phantom attributes' generated by WYSIWYGs, attributes on things that don't exist: <B></B><I></I>

Annoyances

Not testing the page out on more than one browser, or not testing the page on more than one platform

Forgetting to set your body color, because site creators assume users have their background color set to white

No option to skip self indulgent Flash intro or splash pages