wayground logo

Free Printable Worksheets

Font size

S
M
L
XL
Worksheets

HTML & CSS Test

Total questions: 30

Worksheet time: 23mins

Name
Class
Date
1.
HTML tags are enclosed with in which of the following brackets?
a)
Curly brackets {}
b)
brackets ()
c)
square brackets []
d)
angular brackets <>
2.
Header with largest size is displayed using which Header tag?
a)
<H1>
b)
<H6>
c)
<H5>
d)
<H4>
3.
which attribute is used to refer to the source file and its location in img tag
a)
href
b)
src
c)
ref
d)
rel
4.
Which tag is used to make a list of un ordered grocery list
a)
<OL>
b)
<UL>
c)
<DT>
d)
<DD>
5.

What is the correct syntax to change the background color with css?

a)

background-color: purple;

b)

background-color = "purple";

c)

backgroundcolor=orange

d)

change-background-color: purple

6.

TRUE OR FALSE: CSS is used to style web pages

a)

True

b)

False

7.

TRUE OR FALSE: HTML is used to style web pages.

a)

True

b)

False

8.

How do you change the font color with CSS?

a)

font-color: green;

b)

color: green;

c)

change-font-color: green;

d)

fontcolor=green;

9.

Where should you put the link tag to connect your CSS and HTML file?

a)

Between the <head> </head> in HTML

b)

Between the <body> </body> in HTML

c)

None of the above.

10.

TRUE OR FALSE: HTML is used to add content to web pages.

a)

True

b)

False

11.

This is a picture of a ____.

a)

CSS Rule

b)

HTML Rule

c)

Tags

d)

Coding

12.

The blue is called an _____________

a)

Declaration

b)

Selector

c)

Property

d)

Value

13.

The blue is called an _____________

a)

Declaration

b)

Selector

c)

Property

d)

Value

14.

The blue is called an _____________

a)

Declaration

b)

Selector

c)

Property

d)

Value

15.

The blue is called an _____________

a)

Declaration

b)

Selector

c)

Property

d)

Value

16.

CSS is the...

a)

language for designing web pages

b)

longitudinal compass for directions

c)

way we send information to each computer

d)

way we set up each tag

17.
Name an element which doesn't have a closing tag.
a)
<img>
b)
<head>
c)
<body>
d)
<p>
18.
If you want to have more than one property for a CSS selector, what character separates them?
a)
comma (,)
b)
semi-colon (;)
c)
colon (:)
d)
dash (-)
19.
Which is correct CSS syntax? 
a)
{ body; color=black;}
b)
body: color= black
c)
body {color:black;}
d)
(body color is black) 
20.
Select the code below that uses CSS to configure a background color of #000000 for a web page.
a)
body { background-color: #000000; }
b)
body { bgcolor: #000000; }
c)
document { background­-page: #000000; }
d)
None of these
21.
What symbols go around the properties for each CSS selector?
a)
< >
b)
[ ]
c)
{ }
d)
( )
22.

Does it look like this?

a)

True

b)

False

23.
You should save HTML files with which file extension?
a)
.htm
b)
.index
c)
.webpage
d)
.html
24.
What HTML element defines the title of the document?
a)
<title>
b)
<head>
c)
<meta>
25.
What does CSS stand for? 
a)
Creative Style Sheets
b)
Cascading Style Sheets
c)
Colorful Style Spread
d)
Computer Style Spread
26.
Which is the value in this CSS?
p {color: red;}
a)
p
b)
color
c)
red
27.
Which is the selector for a link?
a)
a { }
b)
link { }
c)
href { }
d)
a href { }
28.
What is the difference between HTML and CSS?
a)
CSS is one type of HTML
b)
HTML gives a webpage structure. CSS provides styling.
c)
CSS structures a webpage. HTML strictly provides styling.
d)
There is no difference.
29.

What does an HTML Footer do?

a)

The <footer> tag defines a footer for a document or section.

b)

Absolute

30.

The <nav> tag defines a set of ___________ ?

a)

The Text is shown normal.

b)

Navigation Links