wayground logo

Free Printable Worksheets

NEW

Font size

S
M
L
XL
Worksheets

HTML and CSS

Total questions: 25

Worksheet time: 13mins

Name
Class
Date
1.
Jerry wants to insert a line break into his webpage. Which code should he use?
a)
<ul>
b)
<li>
c)
<br>
d)
<h1>
2.

Annie wants the name of her product to be the main heading at the top of her webpage. Which tag defines

the largest heading?

a)

<h3>Product</h3>

b)

<h5>Product</h5>

c)

<h1>Product</h1>

d)

<h6>Product</h6>

3.
Which tag defines the visible content of a web document?
a)
<head>
b)
<meta>
c)
<title>
d)
<body>
4.
Which tag will create a line break in a web document?
a)
<hr>
b)
<br>
c)
<h1>
d)
<body>
5.
A properly coded HTML tag will always be found between which two symbols?
a)
( )
b)
{ }
c)
[ ]
d)
< >
6.

When using a text editor, what file extension(s) must be used when saving as a web document?

a)

txt

b)

html

c)

doc

d)

css

7.

Which line of code correctly places a gif image named "tiger" from the images folder into a webpage?

a)

<img src="tiger" alt="Bengal Tiger" />

b)

<img gif=tiger alt="Bengal Tiger">

c)

<image source="images/tiger.gif" alt=Bengal Tiger" />

d)

<img src="images/tiger.gif" alt="Bengal Tiger" />

8.
Which is the correct code to insert a horizontal line in a webpage?
a)
<hr>
b)
<br>
c)
<h1>
d)
<li>
9.

In which section is the content of a webpage written?

a)

Head section

b)

HTML section

c)

Body

d)

Title section

10.

Which one of the following is a properly formatted closing tag?

a)

<html />

b)

</html>

c)

<</html>>

d)

<html>

11.

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

a)

body{

background-color: purple;

}

b)

HTML{

background-color = "purple";

}

c)

body{

color=orange;

}

d)

background {

color: purple

}

12.

What is missing from this HTML skeleton?


<!DOCTYPE html>

<html>


<head><title>Title Text</title>

</head>

<body>

<h1>Hello World!</h1>


</html>

a)

</body>

b)

<div></div>

c)

</head>

d)

<head>

13.

How do you change the font color with CSS?

a)

font-color: green;

b)

color: green;

c)

change-font-color: green;

d)

fontcolor=green;

14.

What will this CSS code do?

img {

border-radius: 10px;

padding: 5px

}

a)

It will add rounded corners and some padding to all images in the website

b)

It will add a rounded corner and a border around all images

c)

It will change the format of the first image ONLY

d)

It will add a rounded corner and some padding to the headings in a website

15.

Which of the following is the correct CSS link tag?

a)

<link rel="styles" href="stylesheet.css">

b)

<link href="stylesheet">

c)

<link rel="stylesheet" src="styles.css">

d)

<link rel="stylesheet" type="text/css" href="styles.css">

16.

Which of the following is the ONLY self closing tag?

a)

<img>

b)

<a>

c)

<h4>

d)

<body>

17.

What brackets do you use in CSS?

a)

< >

b)

{ }

c)

( )

d)

[ ]

18.
How do you align text in the center?
a)
text-align: center;
b)
text-align: middle;
c)
text-align: left;
d)
text-align: right;
19.

WHAT website did we use in class as a reference for our code?

a)

w3schools

b)

downloadmoreram.com

c)

Wikipedia

d)

Google

20.
Which of the following is the largest heading? 
a)
h2
b)
h3
c)
h4
d)
h6
21.
HTML stands for...
a)
Hyper Text Markup Language
b)
High Tech Marking Language
c)
High Tech Modem Language
d)
Hyper Tech Markup Lexicon
22.
Defines a paragraph
a)
<pr>
b)
<p>
c)
<para>
d)
<par>
23.

<a>

a)

Defines an article tag

b)

Defines an HTML hyperlink

c)

Defines the link destination

d)

Defines the area

24.

What will this CSS code change?

p {

color: #0000000;

font-family: 'Arial' ;

padding: 20px;

}

a)

It will change the color, font, and padding for any paragraphs in the website

b)

It will change the color, font, and padding for any H1 headings in the website

c)

It will change the color, font, and padding for any images in the website

d)

It will change the color, font, and padding for the FIRST paragraph ONLY in the website

25.

CSS stands for...

a)

Cooperative Standing Style

b)

Continuous Sheet Style

c)

Cascading Style Sheets

d)

Can't See Style