Web technologies in html, Study notes of Computer Science

The structure of HTML documents as blocks of text, including paragraphs and headings. It describes how to format paragraphs and headings using tags and attributes, and how to align them on the screen. It also introduces the horizontal rule tag, which places a line across the screen to break up the page. examples of how to use these tags in HTML code.

Typology: Study notes

2021/2022

Available from 06/11/2022

navyagowd
navyagowd 🇮🇳

5 documents

1 / 4

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
Blocks
In HTML, documents are structured as blocks of text, each of which can be
formatted independently.
The two major blocks of text in HTML documents are
(a) Paragraph
(b) Heading
Paragraph tag :
Most text is part of a paragraph of information. Every paragraph has to be
explicitly tagged within the source of the document. Each paragraph can be aligned
on the screen either to the left, right or centered. The <P>……………</P> tag is used
to divide the text into many paragraphs. The browser displays a space between
different paragraphs. The ending tag </P> is optional.
<P [align = “left”| “Center” | “right”] >………………..</P>
If you align a paragraph either to right or in the center of the screen, always
specify that the next paragraph is aligned to the left.
Heading tags :
While writing web pages, it is necessary to include section headings and sub
headings. There are different levels of headings that the commonly used. HTML has
six levels of headings h1………..h6. All headings require an end tag.
<h1 [align = “left” | “center” | “right”]> ……………</h1>
<h2 [align = “left” | “center” | “right”]> …………… </h2>
<h3 [align = “left” | “center” | “right”]> …………… </h3>
<h4 [align = “left” | “center” | “right”]> …………… </h4>
<h5 [align = “left” | “center” | “right”]> …………… </h5>
<h6 [align = “left” | “center” | “right”]> …………… </h6>
The heading <h1> is used for main titles. We can also use font size, color etc..
attributes in heading tags.
For example:
<html>
<head>
<title> Different colors for different heading tags</title>
</head>
<body>
<center>
<h1> This is H1 tag.</h1>
<h2> This is H2 tag.</h2>
<h3> This is H3 tag.</h3>
<h4> This is H4 tag.</h4>
<h5> This is H5 tag.</h5>
<h6> This is H6 tag.</h6>
pf3
pf4

Partial preview of the text

Download Web technologies in html and more Study notes Computer Science in PDF only on Docsity!

Blocks

In HTML, documents are structured as blocks of text, each of which can be formatted independently. The two major blocks of text in HTML documents are (a) Paragraph (b) Heading Paragraph tag : Most text is part of a paragraph of information. Every paragraph has to be explicitly tagged within the source of the document. Each paragraph can be aligned on the screen either to the left, right or centered. The

……………

tag is used to divide the text into many paragraphs. The browser displays a space between different paragraphs. The ending tag

is optional.

………………..

If you align a paragraph either to right or in the center of the screen, always specify that the next paragraph is aligned to the left. Heading tags : While writing web pages, it is necessary to include section headings and sub headings. There are different levels of headings that the commonly used. HTML has six levels of headings h1………..h6. All headings require an end tag. ** …………… …………… …………… …………… …………… …………… ** The heading **** is used for main titles. We can also use font size, color etc.. attributes in heading tags. For example: _

Different colors for different heading tags

This is H1 tag. This is H2 tag. This is H3 tag. This is H4 tag. This is H5 tag. This is H6 tag._

_

_ Output: Horizontal rule tag : This tag places a horizontal line across the screen. These lines are used to break up the page. The **** tag does not require any end tag. ** Ex :

**

Program:

_ Horizontal Rules

Example Horizontal Rules

_ Output: