T E C h O C E A N H U B

What is HTML?

HTML stands for Hypertext Markup Language. It is the standard markup language used for creating and structuring the content of web pages. HTML uses tags to define the elements and structure of a web page, such as headings, paragraphs, links, images, tables, forms, and more.

HTML tags are surrounded by angle brackets (<>) and are composed of opening tags, content, and closing tags. Opening tags indicate the beginning of an element, while closing tags indicate the end. Some tags are self-closing and do not require a closing tag.

Here’s an example of a basic HTML structure:

<!DOCTYPE html>
<html>
<head>
  <title>My Web Page</title>
</head>
<body>
  <h1>Welcome to My Web Page</h1>
  <p>This is a paragraph of text.</p>
  <img src="image.jpg" alt="My Image">
  <a href="https://www.example.com">Visit Example Website</a>
</body>
</html>

In the example above, the <!DOCTYPE html> declaration defines the document type. The <html> element is the root element of an HTML page. The <head> element contains metadata about the document, such as the title displayed in the browser’s title bar. The <body> element contains the visible content of the web page.

Inside the <body> element, we have various tags like <h1> for headings, <p> for paragraphs, <img> for images, and <a> for links. These tags are just a small representation of the many elements available in HTML.

HTML provides the structure and content of a web page, while CSS (Cascading Style Sheets) is used to control the presentation and layout, and JavaScript is used for dynamic and interactive behavior. Together, HTML, CSS, and JavaScript form the core technologies for building websites and web applications.

Copyright ©TechOceanhub All Rights Reserved.