Skip to main content

Command Palette

Search for a command to run...

Understanding HTML more!

Updated
2 min readView as Markdown
Understanding  HTML more!
S

I am learning frontend development along with data structure .

To structure, to emphasise particular keywords, to improve the accessibility of our web page we use a markup language , which is HTML.

What is HTML?

HTML stands for Hypertext Markup Language, let us understand the meaning of each word . Hypertext means text which contains links to other texts or linking on or more web pages on the same/different websites. Markup means what HTML tags do to the text inside of them; they mark it as a specific type of text. HTML is a Markup Language that tells the web browser how to structure the web page. We use .html/.htm extension to save our file as a HTML file. HTML consists of tags , these tags are in closed in <> and </> symbol .

  • <> This is a opening tag .

  • </> This is a closing tag.

Content is wrapped between these tags.

Syntax of HTML

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>HTML</title>
</head>
<body>
    <h1>Getting started with HTML</h1>
</body>
</html>

Shortcut for this (in VS code) :- !+tab

HTML is very flexible and forgiving language , if you don't the whole code and just write tags and content in between then also you will get your content seen on the browser but this practice is not a standard practice. We have to follow this standard to write our HTML. Now lets understand the syntax:-

-<!DOCTYPE html> :- It declares that this document type is HTML.

- <html> :-It wraps all the content on the page . Sometimes also known as **root element**.

- <head> :- It contains information like such as page <title> , styling <links> . These information are for web browsers. **Web browsers use the information contain in the <head> to render the HTML document correctly.**
The content of the head isn't visible to the users.

- <meta> :- Meta is information about the data. Here charset="UTF-8" is information about the character set that is going to be used.

- <title> :- Sets the title of the page(not heading) that appears in the web browser tab. 

- <body> :- Body contains all the content that appears on the web browser.

HTML play main role in structing the whole website .

Thank you :)