Hyper Text Markup Language (HTML) is a standard markup language for the creation of a web page and web applications.
It allows the creation and structure of sections, paragraphs, and links using HTML elements (the building blocks of a web page) such as tags and attributes.
HTML consists of a series of elements that are represented by tags. These tags are used to define the structure and content of a web page. For example, the <h1>
tag is used to define a heading, and the <p>
tag is used to define a paragraph.
HTML also uses attributes to provide additional information about an element. These are added to the opening tag of an element and are usually made up of a name and a value, separated by an equals sign.
Here are some basic concepts to understand when learning HTML:
- HTML elements: These are the building blocks of an HTML document and are represented by tags. For example, the
<p>
tag represents a paragraph element, and the<img>
tag represents an image element. - Attributes: These provide additional information about an element. They are added to the opening tag of an element and are usually made up of a name and a value, separated by an equals sign. For example, the
src
attribute is used to specify the source of an image, like this:<img src="image.jpg">
. - Headings: Headings are used to create headings and subheadings on a web page. They are represented by the
<h1>
to<h6>
tags, with<h1>
being the most important and<h6>
being the least important. - Paragraphs: Paragraphs are used to create blocks of text on a web page and are represented by the
<p>
tag. - Links: Links, or hyperlinks, are used to connect web pages and are represented by the
<a>
(anchor) tag. Thehref
attribute is used to specify the destination of the link. - Lists: Lists are used to organize content on a web page and can be either ordered (numbered) or unordered (bulleted). Ordered lists are represented by the
<ol>
tag, and unordered lists are represented by the<ul>
tag. List items are represented by the<li>
tag.
<!DOCTYPE html>
<html>
<head>
<title>Page Title</title>
</head>
<body>
<h1>This is a Heading</h1>
<p>This is a paragraph.</p>
</body>
</html>