Forbes magazine logo Ranked Best Coding Bootcamps 2023

What's the difference between HTML 5 and HTML4

Altcademy Team wrote on 7 February 2018

Please give the main difference concerning a front-end web developer.

The official difference is documented on https://www.w3.org/TR/html5-diff/
Changes to note:
New Elements to give you better semantic structure
  • section represents a generic document or application section. It should be used together with the h1, h2, h3, h4, h5, and h6 elements to indicate the document structure.
  • article represents an independent piece of content of a document, such as a blog entry or newspaper article.
  • main represents the main content of the body of a document or application.
  • aside represents a piece of content that is only slightly related to the rest of the page.
  • header represents a group of introductory or navigational aids.
  • footer represents a footer for a section and can contain information about the author, copyright information, etc.
  • nav represents a section of the document intended for navigation.
  • figure represents a piece of self-contained flow content, typically referenced as a single unit from the main flow of the document.
  • template can be used to declare fragments of HTML that can be cloned and inserted in the document by script.
Elements that allow you to add multimedia content directly in HTML
  • video and audio for multimedia content. Both provide an API so application Web developers can script their own user interface, but there is also a way to trigger a user interface provided by the user agent. source elements are used together with these elements if there are multiple streams available of different types.
  • canvas is used for rendering dynamic bitmap graphics on the fly, such as graphs or games.
New input types
  • tel
  • search
  • url
  • email
  • date
  • time
  • number
  • range
  • color


Trusted by

Students and instructors from world-class organizations

Imperial College London
Carnegie Mellon University
City University of Hong Kong
Hack Reactor
Cisco Meraki
University of Oxford
Swift
Bazaarvoice
Waterloo
Uber
AtlanTech
Tumblr
Boston College
Bombardier Aerospace
University of St. Andrews
New York University
Minerva Schools at KGI
Merrill Lynch
Riot Games
JP Morgan
Morgan Stanley
Advanced Placement®
Google
KPMG
The University of Hong Kong
University of Toronto
SCMP
Moat
Zynga
Hello Toby
Deloitte
Goldman Sachs
Yahoo
HSBC
General Assembly
Tesla
McGill University
Microsoft

Join the upcoming Cohort #96

Enroll for December 2nd, 2024