The purpose of the Show If Field Has Changed server behavior A server behavior is a reusable component for server-side development. They add blocks of code to your pages for accomplishing specific tasks. Dreamweaver comes with several default server behaviors and the InterAKT extensions add many more to this list. is to allow the display of a region only when a certain table field changes its value. Before applying it, create a recordset A recordset is the result of executing an SQL query A query is a SQL command that will extract information from the tables of a database. Essentially, a query is a request for information from your database.. It is composed of multiple rows, each row having multiple columns. The columns presented in the query result depend on the column list declared in the query (they can belong to different tables). The number of rows and their order depend on the query conditions (WHERE, GROUP BY, HAVING, ORDER). The recordset acts as a source of dynamic data The InterAKT Dynamic Data tool is a replacement for the standard dynamic data dialog. It is used in the MX Kollection 3, to provide a unified way of building mark-ups, or place holders. These are recordset fields, server or session variables, and other types of dynamic data that are replaced at runtime by their corresponding values in web applications. containing the field to be used in the condition, and then select or create the page content that will be displayed when the field changes. If no content is selected, an error message will be displayed when trying to apply the server behavior.
You can access this server behavior from the Application panel, Server Behaviors -> + -> MX Kollection -> Conditional Regions -> Show If Field Has Changed.
The user interface has two tabs. Directions about their correct configuration are given below.
To set the dialog box options for the first tab, follow the next steps:
The Has ELSE checkbox creates a new region that is displayed when the field changes. It is similar to the one used in the Show If Conditional Region. If the Has ELSE option has been checked, you will have to replace the Else text: replace this with the content that should appear when the specified condition is not met.
The three buttons in the top right corner of the interface offer you the next functionalities:
· Click OK when you are done configuring the server behavior.
· Click Cancel to exit without applying the new settings.
· The Help button opens this help page.
These buttons are common to both tabs of the Show If Field Has Changed server behavior interface.
To set the dialog box options for the second tab, follow the next steps:
After applying this server behavior, at least one translator is shown on page: the one surrounding the initial region. If the Has ELSE option has been checked, then a second translator containing a bogus content ("Else text: replace this") will be displayed. Replace this content with the one you want to display.
In order to change the field that acts as the condition, or to add/remove an ELSE region, simply edit the existing Show If Field Has Changed server behavior from the Server Behaviors tab. When removing an ELSE region, its content will be added after the IF region's content.
Related Topics