|
[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: aborting element creation
Thanks for answering.
Tempore 18:01:03, die 02/10/2005 AD, hinc in xsl-list@xxxxxxxxxxxxxxxxxxxxxx scripsit Michael Kay <mike@xxxxxxxxxxxx>: I've no idea what you mean by "with no decisive structure or patternThis is what I mean with "pattern matching". (Sorry, I'm quite bad at using correct terminology) It solves of course my trivial and fictional XML problem, but is no answer to my real question (which I might have asked in a non-intelligible manner). Your template, when it processes a node with no @encapsulate attribute, is generating an element whose name is "", which will obviously fail.Indeed, but why can't the 'xsl:element' not just do nothing instead of raising an error when the name is empty? So that this template: <xsl:template match="/"> <root> <xsl:element name=""> <node/> </xsl:element> </root> </xsl:template> would generate the same result as: <xsl:template match="/"> <root> <node/> </root> </xsl:template> So <xsl:element name=""/> would be treated somewhat like <xsl:for-each select="."/> I know XSL1.0 does not behave like this; I wanted to know if XSL2.0 did, or if there were tricks to simulate the behaviour without 'xsl:test' or XPath testing.
|
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
|

Cart








