HTML and CSS Reference
In-Depth Information
<input type=”submit” value=”Search”>
</div>
</form>
For now, this is all you need to know about the <form> element to begin building your bookings form. You will be
diving deeper into forms and inputs later in this chapter, but first let's set up the Bookings page.
As usual, this code can be downloaded from the topic's website at http://www.wiley.com/go/treehouse/
html5foundations . The code for this exercise can be found in the code for Chapter 5, folder 1.
Follow these instructions to create the new Bookings page.
1. Create a new file called bookings.html in your favorite text editor and save it in the root of your project
folder.
2. Open the about.html file and copy its contents into your new bookings.html file. Don't forget to
update the <title> and <meta> elements and remove the active class from the Home link in this new
file.
3. Clear out the contents of the <section> element that has the ID page-text .
4. Within this <section> element, create a new <h1> element with the text Request a Booking .
5. Underneath this heading, add the following paragraph of text using a <p> element.
<p>
Please use the form below to submit a booking request. You will then be
contacted by a staff member who will confirm your booking.
</p>
6. Below this paragraph, create a new <form> element.
<form></form>
7. Set the action attribute on this <form> element to bookings.php .
<form action=”bookings.php” ></form>
8. Set the method attribute on this <form> element to POST .
<form action=”bookings.php” method=”POST” ></form>
9. Save your bookings.html file.
Figure 5-2 shows how your Bookings page should look at this stage.
Search WWH ::




Custom Search