|
Usage Example |
|
|
Suppose we have an area in our main page whose content will be different depending on the login status of the users. If the login status of a user is not "LoggedIn", we will provide input fields to the user to log in. After the login is done, the input fields will disappear and the user will be displayed with another content. Insert a condition panel into the page. "Generate Condition As" property is set to its default value of "xsl:when", meaning that the displaying conditional content will be determined with XSL statements. The exclamation mark in the elements signals that no conditions are yet defined.
Create two conditions in the condition panel; one will be displayed to the users which not yet logged in and the second to the users which already logged. We will create the conditions with the following content.
Double click onto the condition panel area to call the Conditions dialog. Add two new conditions using Name the conditions as "LoggedIn" and "NotLoggedIn". Now, we can select the panel of each condition by clicking [Select] in the Conditions window. As you can see in the example below, the contents of conditions can be constructed totally different from each other.
To test this example, prepare an XML file with the content below and give its name to the "XML File for Preview" property of the page.
To test the both conditions, change the value of the <Status> tag in XML file and use preview (F9) command in the Application Studio. See Condition Panel
|