DREAMWEAVER CS3
User Guide
440
Set conditional (When) properties
The purpose of the Set Conditional Region Property inspector is to change the condition used in a multiple condi-
tional region in your XSL page. The multiple conditional region tests the condition and takes a course of action based
on the result.
❖
In the Test box, enter a new condition, and then press Enter.
Insert XSL comments
You can add XSL comment tags to a document, or you can wrap a selection in XSL comment tags.
Add XSL comment tags to a document
❖
Do one of the following:
•
In Design view, select Insert > XSLT Objects > XSL Comment, type the contents of the comment (or leave the box
blank), and click OK.
•
In Code view, select Insert > XSLT Objects > XSL Comment.
You can also click on the XSL Comment icon in the XSLT category of the Insert bar.
Wrap a selection in XSL comment tags
1
Switch to Code view (View > Code).
2
Select the code you want to comment.
3
In the Coding toolbar, click the Apply Comment button and select Apply <xsl:comment></xsl:comment>
Comment.
Use the XPath Expression Builder to add expressions for XML data
XPath (XML Path Language) is a non-XML syntax for addressing portions of an XML document. It is used mostly
as a query language for XML data, just as the SQL language is used to query databases. For more information on
XPath, see the XPath language specification on the W3C website at
www.w3.org/TR/xpath
.
The XPath Expression Builder is a Dreamweaver feature that lets you build simple XPath expressions for identifying
specific nodes of data and for repeating regions. The advantage of using this method instead of dragging values from
the XML schema tree is that you can format the value that is displayed. The current context is identified based on
the position of the insertion point in the XSL file when the XPath Expression Builder dialog box is opened. The
current context is in boldface type in the XML schema tree. As you make selections within this dialog box, the correct
XPath statements, relative to your current context, are generated. This simplifies the process of writing correct XPath
expressions for beginners and advanced users.
Note:
This feature is designed to help you build simple XPath expressions to identify a specific node or for repeating
regions. It does not allow you to edit the expressions by hand. If you need to create complex expressions, use the XPath
Expression Builder to get started and then customize your expressions in Code view or with the Property inspector.
Create an XPath expression to identify a specific node
1
Double-click the XML data placeholder on the page to open the XPath Expression Builder.
2
In the XPath Expression Builder (Dynamic Text) dialog box, select any node in the XML schema tree.
The correct XPath expression is written in the Expression box to identify the node.
September 4, 2007