Subject: RE: [xsl] creating xml:lang attribute From: "Chris Bayes" <Chris@xxxxxxxxxxx> Date: Fri, 30 Mar 2001 11:36:25 +0100 |
Nick, I don't have any problems. <?xml version="1.0" encoding="UTF-8"?> <root xml:lang="en_gb"> <GROUP_NAME>aName</GROUP_NAME> </root> <?xml version="1.0" encoding="UTF-8"?> <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"> <xsl:variable name="Lang" select="/root/@xml:lang" /> <xsl:template match="root"> <NAME> <xsl:attribute name="xml:lang"><xsl:value-of select="$Lang"/></xsl:attribute> <xsl:value-of select="GROUP_NAME"/> </NAME> </xsl:template> </xsl:stylesheet> Produces <?xml version="1.0" encoding="utf-8"?><NAME xml:lang="en_gb">aName</NAME> In Xalan Saxon Msxml Sablotron and Unicorn Oracle produces <?xml version = '1.0' encoding = 'UTF-8'?> <NAME xmlns:xml="http://www.w3/org/XML/1998/namespace" xml:lang="en_gb">aName</NAME> Which is an error Ciao Chris XML/XSL Portal http://www.bayes.co.uk/xml >-----Original Message----- >From: owner-xsl-list@xxxxxxxxxxxxxxxxxxxxxx >[mailto:owner-xsl-list@xxxxxxxxxxxxxxxxxxxxxx]On Behalf Of Nick Laqua >Sent: 30 March 2001 10:51 >To: XSL-List@xxxxxxxxxxxxxxxxxxxxxx >Subject: [xsl] creating xml:lang attribute > > >> Hi guys, >> >> I have a problem creating an xml:lang attribute in my output xml file: >> >> from xsl file: >> ... >> <NAME> >> <xsl:attribute name="lang"><xsl:value-of >> select="$Lang"/></xsl:attribute> >> <xsl:value-of select="GROUP_NAME"/> >> </NAME> >> ... >> >> during processing, an error is thrown "Could not resolve namespace >> prefix xml: ...". This doesn't work with Xalan, but with Saxon. >> >> any ideas ?? >> >> Nick >> >> Nick Laqua >> Manager Software Development >> >> newtron AG >> Frankfurt - Dresden - Singapore - New Delhi >> >> Freiberger Straße 39 (im World Trade Center) >> D 01067 Dresden >> >> phone: +49 (0) 351 4 39 58-130 >> fax: +49(0) 351 4 39 58-177 >> mobile: + 49(0) 171 87 81 303 >> >> the global b2b portal: >> http://www.newtron.net >> >> > > 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 -> |
---|---|---|
[xsl] creating xml:lang attribute, Nick Laqua | Thread | Re: [xsl] creating xml:lang attribu, David Carlisle |
RE: [xsl] Does a transform understa, Michael Kay | Date | [xsl] Generating CGI querystrings: , Ruggier, Mario |
Month |