1. On a website, what is the purpose of HTML code?
Html describes the structure of a website using markup language.
It probides the contents of a website.
2. What is the difference between an element and a tag?
Tags act like containers of the information that lies between their openeing and closing tags.
Elements are made up of two tags: an opening tag and a closing tag. They tell the browser something about the information that sits between its opening and closing tags.
3. Why do we use attributes in HTML elements?
Attributes provide additional information about the contents of an element.
4. Describe the purpose of the head, title, and body HTML elements.
Head: Contains the metadata and information about the page. Metadata is not displayed.
Body: Contains the contents that are going to be displayed inside the main browser window.
Title: This element is located inside the head element. Contents of the title element are shown in the top of the browser, or on the tab for that page.
5. In your browser (Chrome), how do you view the source of a website?
A. View tab -> Developer -> View Source
B. Shortcut (alt) + (command) + U
C. Right Click -> View Page Source
6. List five different HTML elements and what they are used for.
Element | Description
------- | -----------
h1 | are used to define headings
div | are used to define divisions or sections
img | are used to define images
ul | are used to define unordered lists
li | are used to define a list item
7. What are empty elements?
Elements with no content and end tag such as br to create a line break.
8. What is semantic markup?
Markup for text that provides extra information such as emphasis, quotations, or acronyms.
9. What are three new semantic elements introduced in HTML 5? Use page 431 in the book to find more about these new elements.
1. Figure
2. Figcaption
3. Header