0% found this document useful (0 votes)
25 views2 pages

HTML Document

HTML is a markup language used to create webpages. It uses tags like <h1> for headings and <p> for paragraphs. The basic structure of an HTML page includes <html>, <head>, and <body> tags. HTML pages can include lists, tables, and inline or block level elements.

Uploaded by

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

HTML Document

HTML is a markup language used to create webpages. It uses tags like <h1> for headings and <p> for paragraphs. The basic structure of an HTML page includes <html>, <head>, and <body> tags. HTML pages can include lists, tables, and inline or block level elements.

Uploaded by

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

HyperText Markup Language, short for HTML, is a markup language used for creating webpages or

documents. It is the building blocks of the web.

Creating HTML file does not require a server and it must end with the .htm or .html extension. It runs in
a web browser, having index.html as the root or homepage of a website.

Syntax: <tagname>content</tagname>

 The element name should be surrounded by angle brackets


 It can come with or without pair tags (e.g. <html></html>, <br>)
 End tag has a forward slash before the element name.
 Empty tags close themselves as well and the forward slash is placed after the element name
(e.g. <br/>)

Basic Page Structure of HTML

<!DOCTYPE html> <!—Defining the document as HTML5—>


<html>
<head>
<title>Page Title</title>
</head>
<body>
<h1>First-level Heading</h1>
<p>Paragraph</p>
</body>
</html>

Heading provides a title for each section of an HTML document. It ranges from 1 to 6, 1 being the
highest and 6 being the lowest.

Example:

<h1>First Heading</h1>
<h2>Second Heading</h2>
<h3>Third Heading</h3>
<h4>Fourth Heading</h4>
<h5>Fifth Heading</h5>
<h6>Sixth Heading</h6>

Paragraph is a block element usually consisting of at least one sentence.

Example:

<p>This is a sample paragraph element with p element.</p>

Inline vs Block Level Elements

Inline elements do not start on a new line and take only the necessary width. While, block elements
start on a new line and take full width available. Examples of block level elements are <div>, <h1>-<h6>,
<p>, <form>. Examples of inline level elements are <span>, <img>, <a>, <strong>, <em>.
Tag attributes provide additional information to elements. Every tag can have attributes that are placed
within the start tag after the element name with space in between. It is usually paired with a key/value;
it is possible to have a key only without value.

List is a series of items enclosed by either <ul> if unordered and <ol> if ordered. Each of the items within
the list is enclosed by <li>.

Example:

<ul>
<li>First Unordered Item</li>
<li>Second Unordered Item</li>
<li>Third Unordered Item</li>
</ul>

<ol>
<li>First Ordered Item</li>
<li>Second Ordered Item</li>
<li>Third Ordered Item</li>
</ol>

Table consists of rows and columns enclosed by <table>.

You might also like