0% found this document useful (0 votes)
10 views3 pages

A Detailed Lesson On HTML For Noobs

a lesson and introduction on learning html

Uploaded by

aroronglovekate
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
10 views3 pages

A Detailed Lesson On HTML For Noobs

a lesson and introduction on learning html

Uploaded by

aroronglovekate
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 3

A Beginner's Guide to HTML

Introduction to HTML
HTML (HyperText Markup Language) is the standard markup language for creating web pages.
It defines the structure and content of a webpage.

Basic Structure
A basic HTML document consists of three main sections:

1. DOCTYPE declaration: Specifies the document type.


2. HTML element: The root element of an HTML document.
3. Head element: Contains metadata about the webpage, such as title and stylesheets.
4. Body element: Contains the visible content of the webpage.

HTML

<!DOCTYPE html>
<html>
<head>
<title>My First Webpage</title>
</head>
<body>
<h1>Hello, World!</h1>
</body>
</html>

Elements and Attributes


Elements:

● Heading elements: <h1>, <h2>, <h3>, <h4>, <h5>, <h6>


● Paragraph element: <p>
● List elements: <ul> (unordered list), <ol> (ordered list), <li> (list item)
● Link element: <a>
● Image element: <img>
● Table elements: <table>, <tr>, <td>
● Div element: <div> (generic container)
● Span element: <span> (inline container)

Attributes:

● href: Specifies the URL of a link.


● src: Specifies the URL of an image.
● alt: Provides alternative text for images.
● style: Specifies inline styles.

Example: A Simple Webpage

HTML

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

Tips for Beginners


● Validate your HTML: Use online validators to ensure your code is correct.
● Use a code editor: A code editor can help you write HTML more efficiently.
● Practice regularly: The best way to learn HTML is to practice creating web pages.
● Refer to documentation: Consult online resources and tutorials for more information.

By following these guidelines, you can start creating your own web pages using HTML.

Sources
1. https://gitlab.com/-/snippets/2595537
2. https://calcopedia.com/html/

You might also like