Exercise 4

In section 6 of this tutorial, you have seen that you can display all the metadata about the letters in the XML source file using a bulleted list. Now try to present the information in an HTML table. Tables are created using the HTML <table> element. Table rows are created with <tr>, and cells in this table are created using <td>.

Create a table with three cells: the first cell should contain the name of the sender, the second cell should contain the name of the recipient, and the third cell should contain the library callnumber.

As you work on this exercise, you need to think carefully about the placement of the <tr> and the <td> elements. Should they be inside or outside of the body of <for-each>?

Answers | Continue with the tutorial