Subject: Re: [xsl] Create an end element - possible? From: Liam R E Quin <liam@xxxxxx> Date: Sun, 03 Oct 2010 16:11:37 -0400 |
On Sun, 2010-10-03 at 20:04 +0200, [x] cross solution wrote: > >> So now i have to find the "Start" and "End" Tags in the value-of content (the content of <Data> is only an example). > >> Based on this information i have to create a new element "<w:p>" (this works). > >> But to create the </w:p> element doesn't work. > > > > There is nothing like a <w:p> element or a </w:p> element in the data XSLT operates on. > yes, right - i need it only for the WordML XML - Microsoft It's a terminology problem I think. An element is an abstract idea. In the XML document, there is a start tag content an end tag and those make up an element. So, you are trying to generate separate start and tags, not elements. But, that is not how XSLT works - it generates elements. You have two main choices here... (1) write templates that will match the input where there is a common ancestor of the <w:p> and </w:p> tags, so that you can generate a complete element... or... (2) use xsl:text with disable-output-escaping=yes and generate the tags directly (this is fighting XSLT). Liam -- Liam Quin - XML Activity Lead, W3C, http://www.w3.org/People/Quin/ Pictures from old books: http://fromoldbooks.org/ Ankh: irc.sorcery.net irc.gnome.org www.advogato.org
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] Create an end element - p, [x] cross solution | Thread | Re: [xsl] Create an end element - p, [x] cross solution |
Re: [xsl] Mapping from two sources , G. Ken Holman | Date | Re: [xsl] Hyphenation code, Bruno Mascret |
Month |