What is HTML?
HTML is an acronym of Hypertext Markup Language; Let’s Break up the full form and understand it word by word. Hypertext in HTML is used to represent the web pages linked together and markup language represents text documents. It’s a markup language created by Tim Berners-Lee in 1993, this was the first version of the HTML. HTML is called the language of the Web as HTML is used to create web pages and websites ( collection of web pages ). We use HTML tags to define the look and feel of a website. With understanding of tags of HTML and knowledge of how to put them together we can create beautiful website layouts easily.
Features of HTML
- Easy to learn and use:
HTML is one of the easiest language that you can learn and use to create web pages and static websites because of its easy to understand syntax and less requirements all you need is an editor ( Notepad, Sublime, VS code, etc ) and a browser ( google chrome, microsoft edge, uc browser, opera, etc. )
- Platform independent:
It means you can create web pages on any system, processor, operating system and it will execute on any system that’s why it’s platform independent .
- Multimedia Support:
You can add images, audio, videos along with gifs into your webpage with the help of HTML.
- Interpreted language:
HTML is an interpreted language that converts the code into machine language so that machine can understand it. It interpretes or converts code line by line to machine language.
HTML supports hypertexts so we can add hypertexts in our web pages to interlink web pages and make a website .
What is HTML5?
HTML5 is also a HyperText Markup Language that is used to make web pages and websites.
So what does this 5 represent in HTML5 ? 5 in HTML5 represents that it is the 5th version of HTML and also the latest. It’s introduced in 2008 by two separate groups: the World Wide Web Consortium (W3C) and the Web Hypertext Application Technology Working Group (WHATWG).
Features of HTML5
- Browser support:
HTML5 has browser support. It means even if some browsers are not supporting HTML5 you will be able to load webpage on that browser.
HTML5 provides a geolocation feature. With the help of geolocation feature we can insert or implement maps in our web pages for example world map etc.
- Web storage:
HTML provides two types of storage. There are two types of storages session storage( only available within the browser tab or window session ) and local storage ( localStorage is kept even between browser sessions)
HTML5 provides a footer element The footer element is typically found at the bottom or foot of a webpage. It can contain copyright information, links to social media and additional site navigation items.
- New Application Programming Interface (API):
HTML5 features like 2D drawing on a web page, Drag and Drop, timed media playback, browser history management.
HTML Vs HTML5
We now know what HTML and HTML5 are and we have seen how they are related. Let’s see how much they differ from each other.
|Mobile friendliness||HTML is less mobile friendly||HTML5 is more mobile friendly|
|Drag and Drop feature||It does not support drag and drop effects.||It supports drag and drop effect|
|Media support||Does not support audio and video without use of flash player||Support Audio and Video with use of <audio> and <video> tag .|
|Vector Graphics||HTML uses vector graphics with the help of various technologies such as VML, Flash, etc.||Vector graphics is an important part of HTML5 as we use SVG and canvas in it.|
|Storage option||For storage browser cache can be used as temporary storage||For storage Application cache, web SQL database, and web storage can be used in HTML5|
|Error Handling||HTML can not handle inaccurate syntax and any other error . Here inaccurate syntax means that the written syntax (order of tags ) is different from the original syntax . Example of basic syntax : <html> <head> <title> </title> </head> <body> </body> </html>||HTML5 can handle inaccurate syntax and other errors.|
|2-D shapes drawing||Shapes like circle, rectangle, triangle, etc. are not possible to draw in HTML||Shapes like circle, rectangle, triangle, etc. are easy to draw in HTML5 .’|
|Efficiency, speed||As it’s older version, it is not fast, efficient, and flexible with respect to HTML5.||HTML5 is efficient , faster and flexible in comparison to HTML .|
|Browser support||Most old browsers support HTML||New browsers support HTML5 such as Firefox, chrome etc.|
1. Which is better: HTML or HTML5?
As we see in this article, HTML5 provides extra features and functionalities in comparison to HTML and as it is the latest version of HTML so it’s recommended to use HTML5 for easy and fast implementation in comparison to HTML
2. Why do we use HTML5 instead of HTML?
Here are the few reasons why we use HTML5 instead of HTML. HTML5 provides you with more features with respect to the HTML such as audio, video with the help of tags, drag and drop feature, Geolocation, browser support etc.
3. What is HTML5 example?
Here is a simple example of HTML5 where we use all heading tags
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <title>Example of HTML headings tag</title> </head> <body> <h1>Heading level 1</h1> <h2>Heading level 2</h2> <h3>Heading level 3</h3> <h4>Heading level 4</h4> <h5>Heading level 5</h5> <h6>Heading level 6</h6> </body> </html>
4. Can I learn HTML5 without knowing HTML?
Yes you can as HTML5 is just an upgraded version of HTML so the concepts that you will learn in HTML5 is almost the same as HTML.
5. Is HTML5 easy to learn?
HTML is one of the easiest languages to learn to develop web pages because of its simpler syntax and once you start learning it you will realize that there are no complex concepts to figure out.
6. Is it good to start with HTML?
Learning HTML is the same as learning HTML5. It is just that HTML5 is the latest version of HTML with more features so it does not matter whether you start with HTML or HTML5.
7. Is HTML5 any good?
Yes, it is as it provides you many functionalities and features like Vector graphics, browser support, geolocation, etc. and new tags that you can use to create web pages and websites.