What is HTML?

  • HTML stands for Hyper Text Markup Language
  • HTML is the standard markup language for creating Web pages
  • HTML describes the structure of a Web page
  • HTML consists of a series of elements
  • HTML elements tell the browser how to display the content
  • HTML elements label pieces of content such as “this is a heading”, “this is a paragraph”, “this is a link”, etc.

Basic HTML structure:

HTML Code Structure:

Example:

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Tutorialsonweb Title Here</title>
</head>
<body>
  <h2>H2 Tag write here</h2>
  <p>Paragraph Tag</p>
</body>
</html>

 

In This Code-

<!DOCTYPE html>:  This is the document type declaration. Technically it is not a tag. It declares a document as being an HTML document(Version of HTML). This declaration is not case-sensitive.

<html>:This is called a root element. All other elements contained within it.

<head>:  The head Tag is a container for metadata (data about data) and is placed between the tag.

<title> :  Title tag used to assign title in html page. it is used in searching  on search engine like google, yahoo etc 

<body> :  The element contains all the contents of an HTML document, such as headings, paragraphs, images, hyperlinks, tables, lists, etc.

Advantages of HTML:

  • HTML is used to build websites.
  • It is supported by all browsers.
  • This can be integrated with other languages like CSS, JavaScript, etc.

Disadvantages of HTML:

  • HTML can only create static web pages. if you want dynamic website then use server side language like PHP etc.
  • Using HTML you can create website pages.
  • The security feature is not good.