HTML Basics Worksheet
Answer the following questions by adding your answer to the DIV element below each question.
Question 1
What is the significance of the html element in an html document?
The HTML element is the root element. This means that it contains
all the other elements on the page.
Question 2
What is the purpose of the head element in an html document?
The head element contains metadata about the document.
This is information about the document that isn't necessarily displayed on the page.
Question 3
What is the purpose of the title element in an html document?
The title element sets the title of the page. Whatever text is put inside of the title
element will appear on the browser tab.
Question 4
What is the purpose of the body element in an html document?
The body element contains all of the content on the page. There will almost always be
more elements inside of the body element.
Question 5
What is the difference between an inline element and a block element?
An inline only takes up as much width as it needs to while a block element takes
up the full width of the page.
Question 6
What is a self-closing tag?
A self-closing tag, also known as a void element, doesn't have a closing tag.
There usually isn't content inside of this tag, instead it is used for things
like line breaks, images, or other elements that don't need a closing tag.
Question 7
Explain the syntax for adding an attribute to an HTML element?
You would add an attribute by typing the name of the attribute followed by an equals sign.
After the equals sign, you would put the value of the attribute in quotes. For example,
in an "img" tag, you would set the source by typing "src=../images/image.jpg".
Question 8
Add an H3 element that contains the content 'Hello World!'.
Then add a class attribute to the H3 element and set the value of the attribute to "glow".
Hello World!