|
Subject: RE: [xsl] Extracting an attribute value only From: "Michael Kay" <mike@xxxxxxxxxxxx> Date: Mon, 16 Jan 2006 13:19:21 -0000 |
<xsl:template match="content">
<page name="{@page}">
<xsl:apply-templates/>
</page>
</xsl:template>
Michael Kay
http://www.saxonica.com/
> -----Original Message-----
> From: Sebastian Tennant [mailto:sebyte@xxxxxxxxxxxxxxx]
> Sent: 16 January 2006 13:12
> To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
> Subject: [xsl] Extracting an attribute value only
>
> Hi all,
>
> I have an XML doc that begins:
>
> <?xml version="1.0">
> <?xml-stylesheet href="ss.xsl" type="text/xsl" ?>
> <content page="welcome">
> [...]
> </content>
>
> I'd like to create a new XML doc using XSLT that takes the value of
> the page attribute and assigns it to a new attribute in the document
> element of the result tree, like this:
>
> <?xml-version="1.0">
> <page name="welcome">
> [...]
> </page>
>
> I'm going round in circles!
>
> TIA
>
> sdt
| Current Thread |
|---|
|
| <- Previous | Index | Next -> |
|---|---|---|
| Re: [xsl] Extracting an attribute v, David Carlisle | Thread | Re: [xsl] Extracting an attribute v, Sebastian Tennant |
| Re: [xsl] Extracting an attribute v, David Carlisle | Date | Re: [xsl] Namespace attribute probl, Geert Josten |
| Month |