HTML (HyperText Markup Language) is the standard language used to create and design web pages. It provides the basic structure for all web content and helps define elements like headings, paragraphs, links, images, and more. HTML was first developed by Tim Berners-Lee in 1991.
Basics of HTML
Here are some fundamental concepts and components of HTML:
HTML Document Structure
An HTML document starts with a <!DOCTYPE html> declaration and includes essential tags like <html>, <head>, and <body>. Here's a basic structure:
<!DOCTYPE html>
<html>
<head>
<title>My First Page</title>
</head>
<body>
<h1>Hello, world!</h1>
</body>
</html>
Headings and Paragraphs
Headings range from <h1> (largest) to <h6> (smallest). Paragraphs are defined using the <p> tag.
Links and Images
HTML allows linking between pages using the <a> tag, and displaying images using the <img> tag.
Lists
HTML supports two main types of lists:
<ul>: Unordered list (bullets)<ol>: Ordered list (numbered)<li> tag.
Forms and Inputs
Forms allow users to enter data. They include various input types such as text fields, radio buttons, checkboxes, and submit buttons.
<form> <input type="text" placeholder="Enter your name"> <input type="submit" value="Submit"> </form>
In simple words, HTML is the foundation of every website. Learning HTML is the first step toward building beautiful, interactive, and well-structured web pages.