wayground logo

Free Printable Worksheets

Font size

S
M
L
XL
Worksheets

HTML

Total questions: 15

Worksheet time: 6mins

Name
Class
Date
1.

True or False? All HTML documents must start with a document type declaration (for example, <!DOCTYPE html>).

a)

True

b)

False

2.

True or False? The HTML document itself begins with <html> and ends with </html>.

a)

True

b)

False

3.

The visible part of the HTML document is between:

a)

<html> </html>

b)

<head> </head>

c)

<body> </body>

d)

<h1> </h1>

4.

HTML elements are represented using:

a)

tabs

b)

tags

c)

attributes

d)

headings

5.

True or False? HTML elements can be nested (elements can contain elements).

a)

True

b)

False

6.

How many HTML elements are in this example?

a)

3

b)

5

c)

7

d)

6

7.

Which of these statements are true? (Choose up to four answers.)

a)

All HTML elements can have attributes

b)

Attributes provide additional information about an element

c)

Attributes are always specified in the end tag

d)

Attributes usually come in name/value pairs like: name="value"

8.

Which is the proper way to write an h1 tag

a)

<h1>Hello</h1>

b)

<h1>"Hello

c)

{h1}Hello{/h1}

d)

<h1>Hello<h1>

9.

<p> tag is for...

a)

Page of Text

b)

Picture

c)

Paragraph of text

d)

Pineapples

10.

Which code below is correct for a hyperlink

a)

<a>

"https://google.com"

Click Me

</a>

b)

<a>Click Me>

"https://google.com"

</a>

c)

<a herf="https://google.com">

Click Me

</a>

d)

<a href="https://google.com">

Click Me

</a>

11.

src attribute in an image tag means what?

a)

Source of the image

b)

Name of the image

c)

Description of the image

d)

Not used with image tag

12.

Which of the following is the code for a paragraph to be blue?

a)

<td style=“background-color:blue;”>

b)

<h1 style=“font-size:60px;”>

c)

<p style=“color:blue;”>

d)

<tagname style=“property:value;”>

13.

What is the font size in this code: <p style=“color:blue; background-color:yellow;

font-size:60px”>Hello</p>

a)

20pixles

b)

40pixels

c)

50pixels

d)

60pixels

14.
which tag will create the largest heading
a)
<h6>
b)
<h4>
c)
<h2>
d)
<h3>
15.

Which of the following codes would create a horizontal line

a)

<br>

b)

<h1></h1>

c)

<hr>

d)

<p>