9. Adding Server Behaviors
Once you've defined a recordset, you need a way to display the data from the recordset on the page, either one record at a time or several records at once. Unless you include additional server-side code in a dynamic page, Dreamweaver displays only the first record in the recordset and stops there. To display additional records, Dreamweaver includes several built-in server behaviorsprewritten blocks of serverside code you can add to your pages, which let you do things like display multiple records at a time and navigate forward and backward through pages displaying recordset data.
Dreamweaver also includes application objects, which are server behaviors that insert both HTML and server-side code in your page to automate such tasks as displaying multiple records on a page. For example, you can use the Dynamic Table application object to insert not only the HTML code needed to create a table, but also the serverside code needed to make the table fields dynamic and display multiple records in the same tableall in one step.
In this chapter, you'll learn how to insert server behaviors and application objects to display multiple records on a page in a dynamic table; add recordset navigation links, a recordset navigation bar, and a record counter; and display or hide regions on dynamic pages.