Page 83 - Computer - 8
P. 83
Try This
Critical Thinking
Identify and write the name of the HTML tag or CSS property for tables whose description is given below:
(a) Lets you define a caption for the title of an HTML table. ___________
(b) Lets you create a row in an HTML table. ___________
(c) Lets you specify the distance between the borders of adjacent cells. ___________
(d) Lets you specify whether or not table borders should be collapsed. ___________
(e) Lets you create a header cell in an HTML table. ___________
Inserting Images in a Table Cell
You can insert an image in a table cell using the <img> tag.
Lab Activity 3
Experiential Learning
To create a table with images in cells.
1. Open Notepad and create the HTML document as shown below.
<!DOCTYPE html> 2. Open the HTML document in
<html>
<head> <title> Hardware Devices </title> </head> Microsoft Edge.
<style type= “text/css”>
table {caption-side: top; border-style: solid; border-
spacing: 2px 3px; border-collapse: separate; empty-cells:
show; width: 100%; height: 100px; font-size: x-large}
caption {Font: bold 35px Calibri; color: red; text-
transform: uppercase}
td {border-style: solid; border-color: green; font-size:
x-large; text-align: center; vertical-align: middle;
padding: 5px}
img {width: 150px; height: 100px}
h3 {color: blue ; text-align: center; font-size: 20px;
font-family: Comic Sans MS}
</style>
<body>
<table> <caption> Hardware Devices </caption>
<tr>
<td> <img src=“Keyboard.jpg”> <h3> Keyboard </h3> </td>
<td> <img src=“Monitor.jpg”> <h3> Monitor </h3>
</td>
<td> <img src=“Hard Disk 1.jpg”> <h3> Hard Disk
</h3> </td>
</tr>
<tr>
<td> <img src=“Mouse.jpg”> <h3> Mouse </h3> </td>
<td> <img src=“Printer.jpg”> <h3> Printer </h3>
</td>
<td> <img src=“Pen Drive 1.jpg”> <h3> Pen Drive </h3>
</td>
</tr>
</table>
</body>
</html>
WORKING WITH HYPERLINKS
A hyperlink or link, is a word, phrase or an image that stores the address
of some other web page or document. It enables you to navigate from one
topic to the next topic on the same web page or from one web page to
another. When you click on any link, the linked document gets opened. A
link is the most common mode by which the World Wide Web is navigated.
81