Training Guide: Programming in HTML5 with JavaScript and CSS3 Ebook

(Nora) #1

Lesson 2: Working with tables CHAPTER 5 229


Lesson review


Answer the following questions to test your knowledge of the information in this lesson. You
can find the answers to these questions and explanations of why each answer choice is correct
or incorrect in the “Answers” section at the end of this chapter.


  1. You are creating a webpage that will display short stories, and you want the stories to
    be shareable on other sites. Which element should each story be wrapped with?
    A.

    B.

    C.

  2. You want to indicate an important item in your content text. Which element do you use?
    A.
    B.
    C.
    D.

  3. You want to identify the author of webpages on your website by providing the author
    name and email address in the footer of each page. What is the proper way to do this?
    A.
    Author Name

    B. Author Name
    C. Author Name
    D. Author Name


Lesson 2: Working with tables


Tables are the way to lay out data in your HTML document in rows and columns. A table
displays a two-dimensional grid of data. Use the <table> element with the <tr> element to
create table rows and the <td> element to create table details, which are better known as
table cells. This lesson discusses tables in detail.

After this lesson, you will be able to:
■■Create a basic table.
■■Add a header and footer to a table.
■■Create an irregular table.
■■Access column data.
■■Apply style rules to table elements.

Estimated lesson time: 30 minutes