Quick Tips
Don’t use the title attribute for essential information
The title attribute can be used to provide advisory information about an HTML element, but do not use it for essential information since not all users will notice the title text.
Don’t duplicate link text in the title attribute
Repeating a link’s text in its title attribute serves no purpose for the end user. All it does is add noise and increase page size.
Use the p element to create paragraphs
Using p elements instead of multiple br elements to create paragraphs in HTML makes your documents more accessible and easier to style.
The alt attribute is for images only
The alt attribute is valid only for images and provides alternative text used when the image cannot be rendered. Do not use it with links and other non-image HTML elements.
It’s “class”, not “CSS class”
There is nothing called a “CSS class” in HTML or CSS, so please refer to values of the HTML class attribute as classes or class names instead.
Creating valid names with the id attribute
There is a simple rule that defines which characters you may use with the id attribute: begin with a letter, then add any number of digits, hyphens, underscores, colons, and periods.
Specify each HTML document’s main natural language
Always specify which natural language (spoken, written or signed human language) is used for a document’s content. Use the lang and/or xml:lang attributes for this.
The id attribute’s value must be unique
The value of the id attribute must be unique in an HTML document. In other words, the same id value may only occur once.
Quick Tips for web developers and web designers
By starting a new category of posts that focus on quick and simple tips related to front-end web development I hope to help people avoid making some mistakes that I see repeatedly.
Page navigation
Page 1 | Page 2Subscribe / follow
Sponsors
Authentic Jobs
- Senior Iteration Manager at Mutual Mobile (Austin, TX, Te, US)
- Design Director at Happy Cog (Austin, Texas, Te, US)
- Designer at Percolate (New York, NY, Ne, US)
- Mobile web MVP project for a startup at Vendalize
DreamHost web hosting
Use the promo code 456BEREASTREET3 to save USD 20 when you sign up for DreamHost

