Subject: Re: how to insert the *complete* content of a node
From: Jeni Tennison <jeni@xxxxxxxxxxxxxxxx>
Date: Fri, 21 Mar 2003 15:15:09 +0000
|
Hi Danilo,
> Actually I do concern about attributes, so the proposed solution did
> not fit at all with what I need (but thanks a lot anyway!!) So I'm
> still trying with some other solution.
>
> Ah the:
> <xsl:template match="mytag">
> <xsl:copy>
> <xsl:copy-of select="*|@*"/>
> </xsl:copy>
> </xsl:template>
>
> Still does not work.
> I Do not want to print the outer tag (mytag in the example)
Then don't copy it (you're copying it with <xsl:copy> at the moment).
Note that in the above you're only copying *element* children of the
<mytag> element, but you've said that you want to get the *text*node*
children as well. In that case, the following might be more suitable:
<xsl:template match="mytag">
<xsl:copy-of select="node()" />
</xsl:template>
I'm not sure what you want to do about the attributes. If you have:
<mytag attr1="aaa">blabla <foo>some text</foo> blabla</mytag>
what do you want to generate?
Cheers,
Jeni
---
Jeni Tennison
http://www.jenitennison.com/
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
| Current Thread |
- Re: how to insert the *complete* content of a node, (continued)
- Jeni Tennison - Fri, 21 Mar 2003 08:51:07 -0500 (EST)
- Robert P. J. Day - Fri, 21 Mar 2003 09:08:13 -0500 (EST)
- Jeni Tennison - Fri, 21 Mar 2003 09:23:50 -0500 (EST)
- danilo - Fri, 21 Mar 2003 09:49:02 -0500 (EST)
- Jeni Tennison - Fri, 21 Mar 2003 10:11:41 -0500 (EST) <=
- Robert P. J. Day - Fri, 21 Mar 2003 10:20:45 -0500 (EST)
- danilo - Fri, 21 Mar 2003 09:12:24 -0500 (EST)
- David . Pawson - Fri, 21 Mar 2003 09:04:24 -0500 (EST)
- Peter Gibbons-BU - Fri, 21 Mar 2003 10:27:33 -0500 (EST)
|
|