Q.1. What colours do #FFFFFF and #000000 denote? (1 Mark)
Ans: #FFFFFF denotes white and #000000 denotes black.
Q.2. Consider the following HTML statement: (1 Mark)
<body bgcolor = "Blue" alink = "red" vlink = "yellow">
In the above statement, what do you mean by alink and vlink?
Ans: Alink stands for active link while vlink stands for visited link. When the cursor is positioned on the hyperlinked text, the coloured specified in alink attribute (red) is seen. When the link has been clicked once, the colour changes to the one specified in vlink attribute (yellow).
Q.3. Which HTML tag would be used to display power in expression x2 + y=10. (1 Mark)
Q.4. Can we assign justified alignment to a paragraph in HTML? (1 Mark)
Ans: No, All the browsers support left, centre and right alignments but not justified.
Q.5. How is <BR> tag different from <P> tag? (1 Mark)
Ans: <BR> starts a new line within the current paragraph. While <P> starts a new paragraph.
Q.6. How can the font size of a single line on a web page be changed? (1 Mark)
Ans: <P> Hello <FONT SIZE="+2"> World </ FONT> </P>
Q.7. Give an example of an empty element in HTML. (1 Mark)
Q.8. What is a BASEFONT element? What is its use? (1 Mark)
Ans: The BASEFONT element sets the default font size and type. The basefont size may be increased or decreased using the FONT tags.
Q.9. What is a “Tag”? (1 Mark)
Ans: A tag is a coded HTML command that indicates which part of web page should be displayed.
Q.10. Name the attributes of <img> tag which are used for specifying its dimensions in a web page. (1 Mark)
Ans: height & width.
Q.11. Which tag is used to display a horizontal rule on a web page? (1 Mark)
Ans: <HR> or HR
Q.12. Write the HTML code to display a horizontal line of red color. (1 Mark)
Ans: <hr color=”red”>
Q.13. Which tag/attributes of HTML are used to- (1 Mark)
(i) Insert a picture in a web page.
(ii) Insert an empty line in the web page.
Ans: (i) <IMG>
(ii) <BR> OR <P>
Q.14. Which heading element gives the most prominent headings? (1 Mark)
Q.15. Name two attributes of FONT tag of HTML. (1 Mark)
Ans: 1. Size
Q.16. Why do we insert comments in an HTML document, even though they are not displayed on a web page? (1 Mark)
Ans: Comments enable the user to understand the code.
Example: < !- This is a comment->
Q.17. What is the method of viewing the source code of the current page in the web browser? (1 Mark)
Ans: Right click on the web page and then select View Source from the context menu.
Q.18. Identify the errors and write the correct HTML code (1 Mark)
1. <BODY background=”red”>
2. <FONT type=”arial”>
Ans: 1. <BODY bgcolor=”red”>
2. <FONT face=”arial”>
Q.19. Write HTML code to set the image “Vase.jpg” stored in “My Pictures” folder in C: as the background of your webpage. (1 Mark)
Ans: The HTML code is <BODY background=”C:\My Pictures\Vase.jpg”>
Q.20. What is the use of width attribute in HTML? (1 Mark)
Ans: Width attribute specifies the width of a horizontal line in pixels or percent. Its default value is 100%.
Q.21. Name two tags that are present in every HTML code. (1 Mark)
Ans: <HTML>, <BODY>