HTML Introduction: HTML is a HyperText Markup Language. By using this language you can create Static Web Pages and show your content in a good format.
Each text is displayed with HTML tags. So that the web browser can easily understand, how to show which text.
If you learn HTML, you can display your content on the web page according to your need. Like Heading, Paragraph, List, Table, Form, etc
If you want to become a Web Developer or Web Designer. So first of all you should have a basic understanding of HTML. Because it is used with other languages (CSS, JavaScript, PHP, Angular, React js & more).
What is HTML
The full Form of HTML is the Hyper Text Markup Language.
HTML is a standard web language that is used to create static websites and web pages.
HTML is used to create the Structure of the web page.
A text editor is frequently used to write HTML code.
HTML files are saved with a .html extension.
The Web Browser is used to run the HTML code
What is HyperText
Any web page can have many links. So that web pages are linked to each other. So that by clicking on those links, we can easily go from one web page to another web page. Those links are called HyperText.
What is Markup language?
Telling the browser by writing a text with an HTML tag is called Markup Language.
Web Browser shows which text is in which format, for this, the text is written with HTML tags. Which is called Markup.
Like – Paragraph is written with <p> Tag, First Heading with <h1>, Image with <img> Tag.
In this way, the Web Browser understands from HTML Tags which text has to be displayed in which format. That’s why it is called Markup Language.
Syntax of HTML in Hindi
<html></html>
- <html> – Open Tag/ Start tag
- </html> – Close Tag / End Tag
Important Points:-
HTML is not Case-sensitive | This Means that you can write HTML syntax in Camel Case, Upper Case, or Lower Case.
According to Coding Standard, it should be written in lowercase only.
- <html></html> – Lower Case ( Recommended)
- <HTML></HTML> – Upper Case
- <Html></Html> – Camel Case
Note: <html></html> element is the root element of a web page/document. So, All other elements must be defined within the HTML element.
Use of HTML
By using HTML, You can –
- create static websites.
- create Navigation links to redirect from one page to another page.
- create tables to keep data in the tabular format
- create lists to keep data in the list format
- and display images on the website.
- create any kind of form such as a registration form, login form, feedback form, comment form, contact form, etc.
- create audio players to play music
- create video players to play videos
You have known some important usage of HTML. The event you can also use HTML for creating many things. As you progress further, you will know more about its uses.
Advantages of HTML
- HTML is very easy to learn
- HTML is an Open source language. So, You can use it absolutely free
- HTML is written any kind of text editor such as notepad, subline, visual studio, etc.
- HTML does not need any third-party software to execute.
- HTML can be used with its related languages such as CSS, Javascript, PHP, etc
- HTML Page can open in your local browser without connecting to the internet.
Disadvantages of HTML
- HTML is not a programming language
- HTML is not used to create any dynamic content, webpages
- HTML is not able to design pages and content. etc without using CSS
- The layout and content of the web page may look different in different web browsers.
History of HTML
- First of all, Time Berners-Lee has created www in 1989. After that, he had begun to work on an internet-based hypertext system.
- Time Berners-Lee created HTML in 1990 as well as a web browser and server software
- The first time, Tim Berners-Lee released HTML and its tags on the internet was in 1991
- HTML1.0 was released in 1993 to read & display information in the web browser
- HTML 2.0 was relased in 1995. It was the improved version of HTML1.0
- HTML 3.0 was released in 1998 by W3C
- HTML 4.0 was released in 1997 and then after minor changing, it was released again in 1998
- HTML 4.01 was released in 1998 that was very successful it began to use everywhere
- HTML 5 was released in 2014 that is used till now and all the new tags are included in this version.
- Currently, the latest version of HTML is 5.2 which was released in 2017
Why should learn HTML?
You should learn HTML because –
- You can learn HTML very quickly and easily
- You can become a professional web designer or web developer
- You can easily learn other related languages like CSS, javascript, react js, angular, node js, PHP, etc
HTML Basic
You need to know some basic points of HTML. So that you can easily understand the concept of HyperText Markup Language.
What are HTML Documents
HTML pages are also called HTML documents. It is represented by <!DOCTYPE> tag.
The <!DOCTYPE> tag is used so that the Web Browser can easily understand what type of document the web page is made of and can show its Layout and Content correctly.
Syntax –
<!DOCTYPE > is written with HTML–
<!DOCTYPE html>
<!DOCTYPE > is not case-sensitive. So, you can write it in Camel Case, Upper Case, or Lower Case.
According to Coding Standard, it should be written in upper case only.
- <!DOCTYPE></DOCTYPE> – Upper Case ( Recommended)
- <!Doctype></Doctype> – Camel Case
- <!doctype></doctype> – Lower Case
You must write <!DOCTYPE html> at the top of the file so that the browser can easily understand the HTML version.
HTML document always starts with the Open <html> tag and ends with the Close </html> tag. But it is written just after the <! DOCTYPE HTML>.
The visible part of HTML Documents remains within the <body></body> element.
The invisible part of HTML Documents remains within the <head></head> element
Basic Code of HTML
To create any kind of web page, it is necessary to write the basic code of HTML given below, so remember it well –
<!DOCTYPE html> <html> <head> </head> <body> </body> </html>
HTML Basic Tags
There are some basic tags of HTML are given below that are enough to create a simple web page –
- <html> tag – This is the root tag and it always defines the first.
- <head> tag – This is the head tag that is used to define meta pieces of information on the web page.
- <body> tag – This is the body tag that is to display everything on the web page.
- <h1> tag – This is the first heading tag that is used to create a heading for the web page.
- <p> tag – This is the paragraph tag that is used to create paragraphs of the web page.
HTML Basic Document Structure
For your better understanding, here is the basic document structure of HTML. –
How to Write HTML Code
To run HTML code, You will have to follow some basic steps –
Step 1: First of all, Create a folder with the name is html-page
Step 2: Then Create a file with the name index.html in the html-page folder
Step 3: Now, Open the index.html in your text editor
Step 4: Then write the following code in the index.html file
<!DOCTYPE html> <html> <head> <title>Page Title</title> </head> <body> <h1> This Is the Heading </h1> <p> This is the first paragraph </p> <p> This is the second paragraph </p> </body> </html>
Step 5: After that press ctrl + s or use the save option of the text editor to save your HTML code.
How to Run HTML Code
To run HTML code, you will have to use any web browser. So, you can use the most useful browser ‘google chrome
Now, you can run HTML code to enter the full path of the index.html file. After that the result page will be displayed