The Devil’s in the Details

Setting up the site-->
Setting up the search page-->
Setting up the results page-->
Results page continued-->
Details page and dynamic images-->
Wrapping it up-->

Here’s where we finally get to see all the information about our intended adoptee. Open the details.php page. Choose the bindings panel, and again, create a recordset query. By now you know how to choose your connection and table. This time, choose the radio button to select certain fields: breed, name, age, personality, and image.

We also need to filter by the URL parameter we just created for the results page link. Filter will be ID = URL Parameter petID (which is the name we gave our URL parameter in the link.) Say OK to create the recordset. Add placeholder text under each header, and then bind the appropriate database field from your recordset in the bindings panel to the text in the table on the details page.

Details Recordset

Inserting Dynamic Images

In the row where you see the image placeholder, delete the text and add any picture of a cat. It doesn’t matter which you choose for now. I chose angie.jpg. Once the picture appears on the page, click the blue folder icon next to the image source field in the Properties Inspector. When the dialog box opens, choose the Data Source button. The dynamic data appears, and you will choose the image field. Remember that we stored just the name of the image in the database. (Note: If you wanted to set up an independent images folder to store all of the images, you have to have the folder name in the database field as well. A pet name in the database would then look like this: images/angie.jpg.) Our image is all set up, and now all that’s left is to create a link back to the index.html page for the “Back to the Search Page” text.
Note: Four pictures are included in the download. This will be enough to give you an idea of how the dynamic image works.

Details page

Wrapping it up-->