HTML SAMPLE QUESTIONS
1. Which is the correct tag to make a link that will send an email?
A. <a href="sendmail://nicholso_p01@[Link]">
B. <a href="nicholso_p01@[Link]">
C. <a href="[Link]
D. The picture above
Answer: C
2. Which tag makes the largest headline?
A. H1
B. H2
C. H3
D. H4
Answer: A
3. Between which set of tags does most of the content of your web page
need to be placed?
A. <text></text>
B. <body></body>
C. <title></title>
D. <head></head>
Answer: B
4. Which set of tags looks like this? ·Dogs ·Cats ·Birds
A. <ul></ul>
B. <u></u>
C. <ol></ol>
D. <dl></dl>
Answer: A
5. Gif is a __________
A. the language of the Web.
B. common graphic format on the Web.
C. a company that provides access to the Internet.
D. common questions and answers.
Answer: B
6. HTML is ___________
A. a company that provides access to the Internet.
B. common questions and answers.
C. the language of the Web.
D. common graphic format on the Web.
Answer: C
7. A URL is ________
A. a Web Address.
B. file format that retains format on the Web.
C. file format that retains format on the Web.
D. file format used to transfer files from one word processor to another.
Answer: A
8. What is the HTML feature that divides a web page into two or more
scrollable parts?
A. Split Page
B. Frame
C. Form
D. Table
Answer: B
9. A table is a _____
A. ARPAnet.
B. input area on a web page.
C. method used to keep web pages formatted correctly.
D. an interent activity that involves synthesis of information.
Answer: C
10. Table cells are represented by:
A. <TD></TD>
B. <TCELL></TCELL>
C. <TC></TC>
D. <CELL></CELL>
Answer: A
11. Which part of the HTML document would you find your META tag
information?
A. Body
B. Title
C. Form
D. Head
Answer: D
12. To begin a new line without starting a new paragraph, which code
would you use?
A. <l>
B. <newline>
C. <line>
D. <br>
Answer: D
13. To creating a link in a document to a section in the same document,
you would use an ________.
A. suspender
B. extra rollover
C. bookmark
D. anchor
Answer: D
14. To center, right or left justify text or an image, what code would I use?
A. justify
B. align
C. push
D. send
Answer: B
15. To create a drop down list for a form, which syntax would you use?
A. The general <SELECT> and <DROPDOWM> tags.
B. The general <SELECT> and <OPTION> tags.
C. The general <OPTION> and <TEXT> tags.
D. The general <DROPDOWM> and <TEXT> tags.
Answer: B
16. What file extension should HTML files have?
A. .web
B. .page
C. .html
D. .cdr
Answer: C
17. What is the correct HTML for making a checkbox?
A. <input type="ckbox" />
B. <input type="check" />
C. <input type="checkbox" />
D. <input type="box" />
Answer: C
18. Which character entity would you use to display extra spaces on a
webpage?
A. &
B. <
C.
D. &space;
Answer: C
19. What is the correct HTML for creating a hyperlink?
A. <a url="[Link]
B. <a name="[Link]
C. <a href="[Link]
Answer: C
20. What is the correct HTML for making a text area?
A. <input type="textarea" />
B. <input type="textbox" />
C. <textarea>
D. <area>
Answer: C
21. What does HTML stand for?
A. Home Tool Markup Language
B. Hyperlinks and Text Markup Language
C. Hyper Text Markup Language
Answer: C
22. Who is making the Web standards?
A. Mozilla
B. Google
C. Microsoft
D. The World Wide Web Consortium
Answer: D
23. Choose the correct HTML element for the largest heading:
A. <heading>
B. <head>
C. <h6>
D. <h1>
Answer: D
24. What is the correct HTML element for inserting a line break?
A. <lb>
B. <break>
C. <br>
Answer: C
25. What is the correct HTML for adding a background color?
A. <body bg="yellow">
B. <body background-color="yellow">
C. <background>yellow</background>
Answer: A
26. Choose the correct HTML element to define important text
A. <strong>
B. <important>
C. <i>
Answer: A
27. Choose the correct HTML element to define emphasized text
A. <italic>
B. <em>
C. <emp>
Answer: B
28. What is the correct HTML for creating a hyperlink?
A. <a url="[Link]
B. <a href="[Link]
C. <a name="[Link]
D. <a>[Link]
Answer: B
29. Which character is used to indicate an end tag?
A. ^
B. <
C. /
D. *
Answer: C
30. How can you open a link in a new tab of a browser window?
A. <a href="url" target="_blank">
B. <a href="url" new>
C. <a href="url" target="new">
Answer: A
31. Which of these elements are all <table> elements?
A. <table><head><tfoot>
B. <table><tr><td>
C. <thead><body><tr>
D. <table><tr><tt>
Answer: B
32. How can you make a numbered list?
A. <ul>
B. <list>
C. <dl>
D. <ol>
Answer: D
33. How can you make a bulleted list?
A. <ul>
B. <list>
C. <dl>
D. <ol>
Answer: A
34. What is the correct HTML for making a checkbox?
A. <input type="check">
B. <checkbox>
C. <input type="checkbox">
D. <check>
Answer: C
35. What is the correct HTML for making a text input field?
A. <textfield>
B. <textinput type="text">
C. <input type="textfield">
D. <input type="text">
Answer: D
36. What is the correct HTML for making a drop-down list?
A. <select>
B. <list>
C. <input type="list">
D. <input type="dropdown">
Answer: A
37. What is the correct HTML for making a text area?
A. <textarea>
B. <input type="textarea">
C. <input type="textbox">
Answer: A
38. What is the correct HTML for inserting an image?
A. <img alt="MyImage">[Link]</img>
B. <img href="[Link]" alt="MyImage">
C. <image src="[Link]" alt="MyImage">
D. <img src="[Link]" alt="MyImage">
Answer: D
39. What is the correct HTML for inserting a background image?
A. <body background="[Link]">
B. <background img="[Link]">
Answer: A
40. An <iframe> is used to display a web page within a web page.
A. TRUE
B. FALSE
Answer: A
41. HTML comments start with <!-- and end with -->
A. FALSE
B. TRUE
Answer: B
42. Which HTML5 element is used to specify a footer for a document or
section?
A. <section>
B. <bottom>
C. <footer>
Answer: C
43. What is the correct HTML5 element for playing video files?
A. <media>
B. <movie>
C. <video>
Answer: C
44. What is the correct HTML5 element for playing audio files?
A. <mp3>
B. <sound>
C. <audio>
Answer: C
45. Which of the following is true about HTML 5?
A. HTML5 is the next major revision of the HTML standard superseding
HTML 4.01, XHTML 1.0, and XHTML 1.1.
B. HTML5 is a standard for structuring and presenting content on the
World Wide Web.
C. HTML5 is a cooperation between the World Wide Web Consortium
(W3C) and the Web Hypertext Application Technology Working Group
(WHATWG).
D. All of the above.
Answer: D
46. Which of the following tag represents a section of the document
intended for navigation in HTML5?
A. footer
B. nav
C. section
D. dialog
Answer: B
47. Which of the following input control is used for input fields that
should contain an e-mail address in Web Form 2.0?
A. email
B. url
C. number
D. range
Answer: A
48. Which of the following tag insists to have a value in an input control in
HTML5?
A. output
B. placeholder
C. autofocus
D. required
Answer: D
49. Which value of [Link] atribute of WebSocket indicates
that the connection is going through the closing handshake?
A. 0
B. 1
C. 2
D. 3
Answer: C
50. Which of the following is true about 'canvas' tag in HTML5?
A. HTML5 element <canvas> gives you an easy and powerful way to draw
graphics using JavaScript.
B. It can be used to draw graphs, make photo compositions or do simple
(and not so simple) animations.
C. Both of the above.
D. None of the above.
Answer: C
51. Which of the following attribute specifies the context menu for an
element?
A. key
B. contextcontent
C. contextmenu
D. context
Answer: C
52. Which of the following attribute triggers event before the document is
printed?
A. onbeforeprint
B. onafterprint
C. onprint
D. beforeprint
Answer: A
53. Which of the following attribute triggers event when media has reach
the end?
A. ondrop
B. ondurationchange
C. onemptied
D. onended
Answer: D
54. Which of the following attribute triggers event when the document
comes online?
A. onloadedmetadata
B. onloadstart
C. onmessage
D. ononline
Answer: D
55. Attributes consist of a name and a value separated by ___ sign
A. ” ”
B. ,
C. =
D. ;
Answer: C
56. Which of the following are not a markup element in html5?1)
<aside>2) <summary>3) <progress>4) <embed>
A. 1
B. 4
C. 2
D. 3
Answer: B
57. Which of the following is not a media element used in html5?1)
<source>2) <audio>3) <track>4) <time>
A. 1
B. 2
C. 4
D. 3
Answer: C
58. Text/Html is called the __________ of the page
A. content type
B. MIME type
C. content type/MIME type
D. none of these
Answer: C
59. Which element is used to draw graphics images on a web page?
A. script
B. audio
C. embed
D. canvas
Answer: D
60. Which of the following term describes the art of making dynamic and
interactive web pages?
A. DHTML
B. HTML
C. XHTML
D. XML
Answer: A
61. Is it possible to use HTML 5 for the mobile application?
A. Yes
B. No
Answer: A
62. What do you mean by SVG?
A. Secondary vector graphics
B. Scalable vertical graphics
C. Scalable vector graphics
D. Scalable vector graph
Answer: C
63. The sessionStorage object stores the data for __________
A. one session
B. two session
C. three session
D. multiple session
Answer: A
64. Which modern browser does not support the HTML5 tags?
A. IE 8
B. Safari
C. Mozilla
D. Opera
Answer: A
65. Graphics defined by SVG is in_______ format.
A. HTML
B. XML
C. XHTML
D. DTD
Answer: B
66. Frame concept is available in HTML5
A. YES
B. NO
Answer: B
67. __________Function displays the Latitude and Longitude in
geoLocation in HTML5.
A. showLocation()
B. showPosition()
C. both a and b
D. showStatus()
Answer: B
68. Which element provides a secure way to authenticate the user?
A. < keygen>
B. < datalist>
C. < output>
D. < input>
Answer: A
69. The manifest file is _____________
A. Text file
B. HTML file
C. XML file
D. java file
Answer: A
70. How many browser safe colors are there?
A. 16 Million
B. 216
C. 256
D. can't determined
Answer: C
71. Application cache is used for________1) Offline browsing 2) Speed3)
Reduced server load
A. 1 and 2
B. 2 and 3
C. all of the above
D. none of these
Answer: C
72. What is mean by DTD?
A. Document type data
B. Data type definition
C. Document type definition
D. Definition type document
Answer: C
73. Which storage object is used for storing the data with no expiry date?
A. Session storage
B. local storage
C. mass storage
D. stack storage
Answer: B
74. Which of the following attribute(s) isn’t supported by HTML 5?1)
frameborder2) scrolling3) marginwidth4) marginheight
A. 1 and 2
B. 3 and 4
C. all of the above
D. none of these
Answer: C
75. Which attribute allows the inline frame to appear as though it is being
rendered as part of the containing document?
A. sandbox
B. seamless
C. src
D. srcdoc
Answer: B
76. What is W3C?
A. World Wide Web Consortium
B. world wide web corporation
C. world wide web company
D. world wide web controlling
Answer: A
77. terminate() method in HTML5 is used for______
A. terminate everything
B. terminate all method
C. terminate a web worker
D. terminate program
Answer: C
78. Height attribute specifies the height of which frame?
A. iframe
B. jframe
C. inline frame
D. outline frame
Answer: C
79. Following method is used to get the current location of the user in
Geolocation in HTML5?
A. getCurrentPosition()
B. getPosition()
C. getLocation()
D. getCurrentLocation()
Answer: A
80. Which attribute enables a set of extra restrictions on any content
hosted by the <iframe>?
A. src
B. name
C. srcdoc
D. sandbox
Answer: D
81. Where does web worker(s) script run?
A. in foreground
B. in background
C. both a and b
D. Can’t determine
Answer: B
82. _________ allows you to set some element to be editable inside the
browser.
A. Spellcheck
B. contenteditable
C. dropzone
D. contextmenu
Answer: B
83. __________ property returns the url of current audio/video.
A. currentSrc
B. controls
C. ended
D. mediaGroup
Answer: A
84. Which of the following are input type attribute in html5?1) search2)
datetime3) week4) color5) track6) placeholder
A. 1,2,3,4,6
B. 1,2,3,4,5
C. 2,3,4,5,6
D. 1,3,4,5,6
Answer: A
85. In HTML 5 width attribute specifies the width of the-----------------
A. inline frame
B. outline frame
C. frameset
D. table
Answer: A
86. Given statement is true or false: “Web worker script is dependent on
other script”
A. Yes
B. no
Answer: A
87. Following code is used for<video width=“320? height=“240?
controls=“controls”> <source src=“test.mp4? type=“video/mp4? />
</video>
A. display audio
B. display video
C. display text
D. display image
Answer: B
88. The doctype should already be on the first line of every HTML page
A. yes
B. no
Answer: A
89. SVG graphics do not lose quality when they are resized?
A. TRUE
B. FALSE
C. can’t determine
D. None of these
Answer: A
90. ____________tag is used to specify an inline frame
A. < jframe>
B. < frameset>
C. < iframe>
D. < frame>
Answer: A
91. For defining the possible line break which tag do we have to use in
HTML 5?
A. < video>
B. < track>
C. < summary>
D. < wbr>
Answer: D
92. The __________ is an instruction to the web browser about the
version of HTML page.
A. < !DOCTYPE>
B. < DOCTYPE>
C. < TYPE>
D. < !TYPE>
Answer: A
93. If your browser supports HTML 5 microdata API, there will be a
_______function on the global document object.
A. getItems()
B. getData()
C. getText
D. getContent()
Answer: A
94. Which one of the following is an open source JavaScript library that
enables styling for HTML5 elements in versions of Internet Explorer
before IE 9 ?
A. HTML5
B. HTML5 Shiv
C. HTML5 Shim
D. HTML5 Sham
Answer: B
95. Which one of the following is not a step to install a library you need to
perform the compatibility in browsers?
A. Download the library from the github location
B. Uncompress the file
C. Insert the following code inside the head tag
D. None of the mentioned
Answer: D
96. Which property is used to detect the browser’s user agent and code
based on the pertinent cases?
A. [Link]
B. [Link]
C. navigator
D. return
Answer: A
97. Some users have requested tests for IE’s float double margin bug, and
support for position:fixed. Which API is suitable for them?
A. mq() media Plugin API
B. addTest() Plugin API
C. testAllProps() Plugin API
D. none of the mentioned
Answer: B
98. ___________ is an open source JavaScript library that allows support
for different levels of experiences based on the capabilities of each
browser.
A. Navigator
B. Modernizr
C. Geolocation
D. Google API
Answer: B
99. ____________ allows you to add custom styles to the document and
test an element afterwards.
A. hasEvent()
B. testAllProps()
C. testProp()
D. [Link]()
Answer: D
100. Modernizr does actually add missing functionalities to browsers save
for the HTML5 tags styling support.
A. TRUE
B. FALSE
Answer: B
101. ___________ is used to test whether geolocation is supported in old
browsers.
A. Modernizr
B. [Link]
C. [Link]
D. [Link]
Answer: C
102. ____________ is a resource loader (CSS and JavaScript) that was
made to specifically to work side-by-side with Modernizr.
A. HasEvent()
B. [Link]
C. [Link]
D. [Link]
Answer: C
103. In case we want to implement a JavaScript fallback, we would need
to create a conditional statement using Modernizr.
A. TRUE
B. FALSE
Answer: A