You can set conditions on individual XML elements by defining a value for the element's @ishcondition attribute. Within a single @ishcondition attribute, the value can be a simple name-value pair or a complex expression.
Before you begin
The condition names and values that are available must have been defined by your publication or project manager. Before applying conditions to content, be sure that you fully understand which conditions you should use and how you should use them. If you have questions, discuss this with an information architect within your organization.
Procedure
- With the object checked-out of the repository and displayed in your authoring tool, click inside an XML element.
Note: Be careful to apply the condition to the appropriate level in the element hierarchy.
- Click
The Condition Builder window displays.
- Click the Tree tab to access the condition values established for the publication.
- Traverse the tree to find the condition to set.
Tip: Conditions names are listed in alphabetical order. You can use the filter options to find conditions based on text that occurs in either the condition name or any of the condition values.
- Compose the condition by selecting the condition and a value or when necessary, enter a value.
- Click Add>>.
If the element already had a condition, the condition is copied to Condition Builder where you can extend the condition or overwrite it.
The condition is added under the Conditions tab as equal to.
- To build complex conditions (optional):
- After adding conditions, select two or more conditions from the conditions list.
- Select the desired logical operator by clicking the AND or OR button.
Any condition in the conditions list can be combined with other conditions in the list to create more complex condition combinations using the Boolean AND or OR operators.
- Close the window by clicking:
| Option | Description |
|---|
| OK | Applies the selected condition to the data between the tags where your cursor is located .
Note: The condition is inserted in the ishcondition attribute of the element in which you placed the cursor.
|
|---|
| Close | Saves the condition without applying it to the data. |
|---|
What to do next
Verify that the conditional content appears correctly in the various outputs. When the topic is used in multiple documents that have different condition contexts, be sure the output is correct for all the variations.