Misconception: Students may accidentally use obsolete, invalid, or non-existent elements, attributes, or properties when learning web development.

  • For example, consider the following errors where novices use elements, attributes, and properties that once were valid but are no longer supported.
    • <center></center>
      • The center tag is an obsolete HTML tag that centered it’s content on a page. With the implementation of HTML5, use of the center tag is incorrect. Students should be using CSS instead.
    • <font color="red"></font>
      • Like in the example above, the font tag is no longer supported in HTML5. This is an unsupported and obsolete element. Students should be using CSS to style their elements instead.
  • Additionally, consider the following errors where novices use elements, attributes, or properties that do not exist and never have.
    • <sidebar></sidebar>
      • Sidebar has never been an HTML tag.
        • It is likely that a novice was trying to place elements into a container on the side of a website that may colloquially be referred to as the sidebar.
  • This type of error is called a rules-based error. It occurs when the student is familiar with the basic rules and constructs of a language, but comes up against an unknown exception, edge case, rule, etc.
    • This may be the result of incorrect research or assumptions about what is valid, or it can simply be the result of not knowing all the rules, exceptions and edge cases for programming with HTML and CSS.

More about this tip

External Source

"Towards a Taxonomy of Errors in HTML and CSS" by Thomas Park, Ankur Saxena, Swathi Jagannath, Susan Wiedenbeck, and Andrea Forte.