Subject: RE: [xsl] multi-document question From: "Ben-Zvi, Elisha" <elisha.ben-zvi@xxxxxxx> Date: Sun, 23 Nov 2003 17:20:50 +0100 |
Hi Bruce, Why don't you change the code to: <xsl:copy> <xsl:copy-of select="*@|node()" /> </xsl:copy> -------------------------------------- Elisha Ben-Zvi Mail: elisha.ben-zvi@xxxxxxx Phone: (972)-9-7620242 Cellular: (972)-66-232304 -----Original Message----- From: Bruce D'Arcus [mailto:bdarcus@xxxxxxxxxxx] Sent: Sunday, November 23, 2003 18:11 PM To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx Subject: Re: [xsl] multi-document question On Nov 23, 2003, at 4:54 AM, Andreas L. Delmelle wrote: > Try replacing this: > >> <xsl:copy> >> <xsl:apply-templates select="@* | node()"/> >> </xsl:copy> > > with : > > <xsl:copy-of select="." /> Thanks Andreas! This almost does this trick. With this, then: <xsl:template match="mods"> <exsl:document href="{@id}.mods" method="xml"> <xsl:copy> <xsl:copy-of select="." /> </xsl:copy> </exsl:document> </xsl:template> I get this: <mods> <mods id="one"> <para>one</para> </mods> </mods> The problem is the repeating mods root elements, and I either need this... <modsCollection> <mods id="one"> <para>one</para> </mods> </modsCollection> ...or just: <mods id="one"> <para>one</para> </mods> I assume I need to modify the <xsl:copy-of select="." />, but I'm unsure how. Also, this schema requires a namespace declaration on the root. How do I get that in the xslt? Finally, I should probably tackle is this: I am using some identifier to name the individual files. In this case it is the id on the mods element. In other cases, it will be another element within mods called identifier with a type attribute value of citekey. In still other cases, this identifier may be missing altogether and I'd want to construct by perhaps selecting the first author family name and the year. If I want to do this, what is the best strategy? Thanks, Bruce XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
RE: [xsl] multi-document question, Michael Kay | Thread | Re: [xsl] multi-document question, Bruce D'Arcus |
Re: [xsl] multi-document question, Bruce D'Arcus | Date | Re: [xsl] multi-document question, Bruce D'Arcus |
Month |