|
[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Namespace questions
Hi All,
I have the following questions:
1. Below are the input and output required. The XSL I wrote and the
actual result. Do you know how should I make it work ?
Input:
<m:A xmlns:m="B">
<A1>something </A1>
<A2 att="att1>something </A2>
</m:A>
Output:
<A >
<A1>something </A1>
<A2 att="att1>something </A2>
</A>
Part of my XSL - In this moment just trying to copy the child's
element (A1, A2)
<xsl:template match="">
<xsl:apply-templates/>
</xsl:template>
<xsl:template match="* | @* | comment() | text() |
processing-instruction()">
<xsl:copy>
<xsl:apply-templates select="* | @* | comment() | text() |
processing-instruction() "/>
</xsl:copy>
</xsl:template>
<xsl:template match="text()">
<xsl:value-of select="."/>
</xsl:template>
What I got is something like this:
<A1 xmlns:m="B">something </A1>
<A2 xmlns:m="B" att="att1 >something </A2>
2. I have to output this line :
<m:A xmlns:m="B">
This line is some where in the tree (not top and not first child) . I
tried to use xsl:element . It complained (Xalan processor) that it
doesn't know m.
I solved this problem by using xsl:text . Which is not very elegant
solution. I wander if you have a better one ?
Thanks,
Ayelet
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
|
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








