wayground logo

Free Printable Worksheets

NEW

Font size

S
M
L
XL
Worksheets

HTML QUIZ 4

Total questions: 20

Worksheet time: 20mins

Name
Class
Date
1.

Which HTML tag is used to change the background color of a webpage?

a)

<head>

b)

<body>

c)

<bgcolor>

d)

<html>

2.

Which attribute is used to set the background color inside the <body> tag?

a)

color

b)

background

c)

bgcolor

d)

stylecolor

3.

Which is a correct example of setting a background color?

a)

<body color="yellow">

b)

<body bg="yellow">

c)

<body bgcolor="yellow">

d)

<body style="bgcolor:yellow">

4.

Which tag is used to insert an image in HTML?

a)

<image>

b)

<img>

c)

<pic>

d)

<src>

5.

Which image file type is supported by HTML?

a)

.docx

b)

.mp3

c)

.jpg

d)

.pptx

6.

Which attribute specifies the image file location?

a)

href

b)

src

c)

link

d)

path

7.

What HTML tag is used to insert audio?

a)

<sound>

b)

<mp3>

c)

<music>

d)

<audio>

8.

Which tag makes text move across the webpage?

a)

<move>

b)

<scroll>

c)

<animate>

d)

<marquee>

9.

To use an image as a background, which attribute is used?

a)

img

b)

background

c)

bgimage

d)

picture

10.

Where should the background image file be located?

a)

any folder

b)

desktop only

c)

same folder as the HTML file

d)

download folder

11.

Which CSS property makes the background image cover the whole page?

a)

background-repeat

b)

background-position

c)

background-size: cover

d)

background-fit

12.

Which attribute automatically plays audio or video?

a)

play

b)

start

c)

autoplay

d)

run

13.

Which is the correct combined syntax for multiple background attributes?

a)

<body background="img.jpg" size="cover">

b)

<body style="background-size: cover; background-repeat: no-repeat;" background="img.jpg">

c)

<body style="cover no-repeat">

d)

<body img="background.jpg">

14.

Which attribute reserves space for a video before it loads?

a)

controls

b)

autoplay

c)

width and height

d)

loop

15.

Why is it important to specify video width and height?

a)

To improve color quality

b)

To reserve page layout space

c)

To reduce file size

d)

To improve sound quality

16.

Which image extension is NOT supported in HTML?

a)

.png

b)

.gif

c)

.html

d)

.jpeg

17.

What happens if the image extension name is incorrect?

a)

page crashes

b)

image rotates

c)

image will not display

d)

image become blurry

18.

Which tag can embed external multimedia directly into a webpage?

a)

<audio>

b)

<video>

c)

<embed>

d)

<img>

19.

Which attribute displays play, pause, and volume?

a)

menu

b)

controls

c)

panel

d)

toolbar

20.

Which of the following is a correct audio tag example?

a)

<audio src="song.mp3"></audio>

b)

<audio="song.mp3">

c)

<sound src="song.mp3">

d)

<mp3>song.mp3</mp3>