html_4
html_4
An HTML document consists of several key components that define its structure.
Every HTML page follows a basic template, which includes essential elements such as
<html>, <head>, and <body>. Below is an example of a simple HTML document:
<!DOCTYPE html>
<html>
<head>
<title>My First Web Page</title>
</head>
<body>
<h1>Welcome to My Website</h1>
<p>This is a paragraph of text on my first web page.</p>
</body>
</html>
<!DOCTYPE html>: Declares the document type and version of HTML being used.
<html>: The root element that encloses the entire HTML document.
<head>: Contains metadata such as the document title, character set, and linked
stylesheets or scripts.
<title>: Defines the title of the webpage, which appears in the browser tab.
<body>: Contains the main content of the webpage, including headings, paragraphs,
images, and other elements.