Subject: Re: [xsl] Design question From: Antonio Fiol <fiol@xxxxxxxxxx> Date: Wed, 10 Jul 2002 10:50:41 +0200 |
The reason Jay couldn't use that is that for some arrangements of parameters this would lead to attributes being added after child elements have already been added to the da:Positive element, which is an error in XSLT.
For example, with the input specified:Oops!
<test type="positive" name="Test 1"> <param name="p1">123</param> <param name="date1">July 9</param> <param name="p2">false</param> </test>
Your code is equivalent to:
<da:Positive name="@name"> <!-- [sic -- forgot {}s] -->
<xsl:attribute name="p1">123</xsl:attribute> <xsl:element name="da:Date"> <xsl:attribute name="number">1</xsl:attribute> </xsl:element> <xsl:attribute name="p2">false</xsl:attribute> </da:Positive>
Processors that don't halt when they encounter an attribute beingIndeed, bad luck...
added after element content ignore the attribute, so either you get an
error or erroneous output; either way it's not much good.
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] Design question, Jeni Tennison | Thread | Re: [xsl] Design question, Jeni Tennison |
Re: [xsl] Design question, Jeni Tennison | Date | [xsl] Design Issues in XSLT, Emmanuel Oviosa |
Month |