KnowledgeBoat Logo
OPEN IN APP

Chapter 7 - Unit 1

HTML - Advanced Features: More Features on HTML

Class 7 - APC Understanding Computer Studies


State whether the following statements are True/False

Question 1

You can display an HTML document in bulleted form by using bullet styles taking bulleted list from MS Word.
False

Question 2

A browser interprets the HTML codes on web page.
True

Question 3

In an ordered list, the contents are displayed in bulleted form.
False

Question 4

You can add a visual appeal by inserting images in an HTML document.
True

Question 5

By default, border is added to a picture in an HTML document.
False

Question 6

You can also insert pictures in HTML documents from an external source.
True

Name the following

Question 1

Two ways to display HTML list

Answer

1. Unordered list
2. Ordered list

Question 2

Two attributes of the Marquee tag

Answer

1. Direction
2. Behaviour

Question 3

Two ways to customize the pictures in HTML documents

Answer

1. Adding border
2. Adding text

Write down the syntax of the following with reference to HTML

Question 1

Ordered List

Answer

<ol>
<li> Line 1 </li>
<li> Line 2 </li>
<li> Line 3 </li>
<li> Line 4 </li>
</ol>

Question 2

Unordered List

Answer

<ul>
<li> Line 1 </li>
<li> Line 2 </li>
<li> Line 3 </li>
<li> Line 4 </li>
</ul>

Question 3

Marquee Tag in left direction

Answer

<marquee direction = "left"> Content </marquee>

Question 4

Marquee Tag in downward direction

Answer

<marquee direction = "down"> Content </marquee>

Question 5

Inserting a picture

Answer

<img src="URL/Path">

Define the following HTML tags

Question 1

Marquee Tag

Answer

This is a special tag used in an HTML document to give an extra effect to a string or a block of text. Generally, it is used to scroll a block of text within the web page. It has two attributes- direction and behaviour.

Syntax:

<marque>string of text</marque>

Example:

<marque>Hello</marque>

Question 2

Ordered List

Answer

In an ordered list, each item is displayed along with the numbers or letters instead of bullets. The entire content of the list is enclosed in <ol> and </ol> tags and each item is enclosed in <li> and </li> tags.

For example:

<ol>
<li> English </li>
<li> Hindi</li>
<li> Maths </li>
<li> Science </li>
</ol>

Question 3

Behaviour in Marquee Tag

Answer

Behaviour is a part of marquee which states about the types of movements of the string of text. It includes three attributes:

  1. Alternate — The string keeps on scrolling between the ends of the web page.
  2. Scroll — The string of text keeps on scrolling across the screen and scrolls back on the web page.
  3. Slide — The string of text starts scrolling from the right side of the screen and stops as soon as it reaches the left side of the web page.

For example:

<marquee behavior = "alternate">Hello Students</marquee>

Question 4

Adding border to a picture

Answer

We can enhance the images on the web page by adding border to the images. This task can be done by using the Border tag.

Syntax:

<img src="URL/Path" Border = "thickness in pixels">

Example:

<img src="d:/images/computer.jpg" Border = "5">

Question 5

Adding text along with a picture

Answer

We can also add captions for the pictures in HTML. By default, the text adjacent to the picture is aligned bottom. Align tag can be used to align the caption on top, middle or bottom of the image.

For Example:

<p><img src="d:/images/computer.jpg" align = "top">Computer - A Machine</p>

Short Answer Questions

Question 1

What are the different attributes of Marquee tags? Name them.

Answer

The different attributes of marquee tag are as follows:

  1. Direction — It has four attributes- left, right, up and down.
  2. Behaviour — It has three attributes - alternate, scroll and slide.

Question 2

Distinguish between Unordered list and Ordered list.

Answer

Unordered listOrdered list
In an unordered list, each item is displayed with a bullet.In an ordered list, each item is displayed along with the numbers or letters instead of bullets.
<ul> and </ul> tags are used.<ol> and </ol> tags are used.

Question 3

How will you perform the following tasks in an HTML document?
(a) Adding border to a picture
(b) Resizing a picture
(c) Right direction of Marquee tag

Answer

(a) Adding border to a picture

We can add border to a picture by using the border tag.

Syntax:

<img src = "URL/Path" border = "thickness in pixels">

Example:

<img src = "d:/images/computer.jpg" border = "5">

(b) Resizing a picture

We can resize a picture by using the attributes Height and Width with <img> tag. Height specifies the height of the picture and width specifies the width of the picture.

Syntax:

<img src = "URL/Path" Height = "height in pixels" Width = "width in pixels">

Example:

<img src = "d:/images/computer.jpg" Height = "400" Width = "300">

(c) Right direction of Marquee tag

Right direction of the marquee tag can be set by using the attribute direction.

Syntax:

<marquee direction = "right">string of text</marquee>

Example:

<marquee direction = "right">Hello students</marquee>

Write all the steps

Question 1

To insert pictures in an HTML document

Answer

To insert pictures in an HTML document, we can use <img> tag, which is an empty tag. To add an image to the web page, we need to specify the complete path of the source.

Syntax:

<img src = "URL/Path"> where 'src' stands for source 

Example:

<img src = "d:/images/computer.jpg">

Question 2

To add borders to pictures in an HTML document

Answer

To add borders to pictures in an HTML document, we can use the border tag.

Syntax:

<img src = "URL/Path" Border = "thickness in pixels">

Example:

<img src = "d:/images/computer.jpg" Border = "5">

Question 3

To add space around pictures/images in an HTML document

Answer

To add space around pictures/images in an HTML document, we can use the tags 'Hspace' and 'Vspace'. Hspace adds white space to the left and right of the pictures and Vspace adds white space above and below the pictures.

Syntax:

<img src = "URL/Path" Hspace = "space in pixels" Vspace = "space in pixels">

Example:

<img src = "d:/images/computer.jpg" Hspace = "100" Vspace = "30">

Question 4

To resize the pictures/images in an HTML document

Answer

To resize the pictures/images in an HTML document, we can use the attributes 'Height' and 'Width' with <img> tag.

Syntax:

<img src = "URL/Path" Height = "height in pixels" Width = "width in pixels">

Example:

<img src = "d:/images/computer.jpg" Height = "300" Width = "400">
PrevNext