[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] RE: Pipe Question
> If defined like this: > <xsl:param name="my_param" select="/"/> > > Or this: > <xsl:param name="my_param" select="."/> > > And the param "my_param" is not supplied you will end up with a copy > of the document source "/" or current context "." (respectively). Do > I have this correct? No, you don't get a copy, you get the original. > > $match is a parameter for one of my templates. The intent of the > template: SELECT ALL -or- SELECT ALL where @component = $match. > > In this example: > <xsl:template match="X[@component=$match] | > X[not(@component=$match)]"/> > > Select ALL X elements who's @component is one of the $match elements > -OR- when $match does not exist, SELECT ALL. If a variable doesn't exist, you get an error. For any condition, match="X[condition] | X[not(condition)]" is equivalent to match="X" except in the special case where evaluating the condition causes an error. Michael Kay http://www.saxonica.com/
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|