CBSE Class 10 Computer Applications
Question 34 of 81
Images, Links and Tables — Question 6
Back to all questions 6
Question Question 6
Write the HTML code to:
i. Align the content of a cell in a Table to the top
ii. Link to a specific section of another webpage
i. To align the content of a cell in an HTML table to the top, we can use the 'valign' attribute with the value "top" for the <td> element. Consider the given example,
<TABLE>
<TR>
<TD VALIGN = "TOP"> Mouse </TD>
<TD>Monitor </TD>
</TR>
<TR>
<TD>Keyboard </TD>
<TD>Printer </TD>
</TR>
</TABLE>
ii. To create a link to a specific section of another webpage, we can use anchor tags <a> with the 'href' attribute pointing to the target webpage and specifying the target section using a '#' followed by the section's 'name' attribute. Consider the given example,
<a href="https://computerhardware.com#inputdevices">Input Devices</a>
Here, "inputdevices" is the value of the 'name' attribute which refers to a specific section of another webpage.