WorksheetsHTML & CSS Practice
Total questions: 20
Worksheet time: 15mins
Which property is used to change the background color in HTML code?
color
bgcolor
background-color
How do you add a color for <h1> element using Inline CSS?
h1{color:blue;}
<h1 style="color:blue">
What is wrong with the code <body>Hello<body/>?
it should be </body>Hello<body>
it should be </body>Hello</body>
it should be <body>Hello</body>
it should be <body>Hello<body>
What attribute of the img tag displays things on the page if the picture cannot be?
src
alt
style
height
What is wrong with the code <br>?
nothing
it should be </br>
it should be <br \>
it should be <br />
What HTML tag makes a link?
<a>
<tr>
<img>
<br>
What HTML tag do you put things in if you want them to appear on the page?
<html>
<head>
<body>
<p>
Which is the correct Internal CSS style to add 'yellow' background color to web page?
p
{color:yellow;}
body
{color:yellow;}
body
{background-color:yellow;}
body
{bgcolor=yellow}
Which of the below is the abbreviation of CSS ?
Cascade sheets style
Color and style sheets
Cascading style sheets
Coded Style Sheet
Which is the correct CSS syntax?
{p:color=black(p}
p {color: black;}
{p;color:black}
p:color=black
Which HTML tag is used to define an embedded style sheet?
<script>
<style>
<CSS>
<body>
Where are inline styles typed?
In the external style sheet
Inside the <style> tag
Inside the <head> tag
In the body, inside the element tag
Which is the value in this CSS?
p {color: red;}
p
red
color
In this code <img src
What does img stand for?
iMac
amazing
image
picture
Write code to add pink color to your h2 tag using Internal CSS.
Write code to add blue color to your p tag using Inline CSS.
Which tag is used when creating a list with a specific order (by default, will show up as a numbered list)?
<ul>
<li>
<ol>
<p>
What is the correct HTML for inserting an image?
<image src="image.gif" alt="A Saskatchewan flag picture.">
<img href="image.gif" alt="A Saskatchewan flag picture.">
<img src="image.gif">
<img alt="A Saskatchewan flag picture.">image.gif</img>
Where in an HTML document is the correct place to include Internal CSS in your HTML?
In the <body> section
At the top of the document
In the <head> section
At the end of the document
If you want to use a background color for your entire webpage, which tag should you select in your CSS?
<body>
<html>
<h1>
<p>
