xml-xalan-j-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Tevoi Andrea" <te...@cad.it>
Subject RE: namespace dynamic creation
Date Fri, 11 Oct 2002 10:00:37 GMT
Thanks Andrew, but i've already seen Jeni site.
Now, xsl solution to my problem is to create a dummy attribute as i've
described in my mail. Infact, it works with Microsoft Parser, but it
doesn't with Xalan (2.4). So I think it could be a Xalan bug...

Note that my solution works with XSLTC...

thanks again,

Andrea

-----Original Message-----
From: Andrew Welch [mailto:awelch@piper-group.com]
Sent: venerdì 11 ottobre 2002 11.37
To: Tevoi Andrea; xalan-j-users@xml.apache.org
Subject: RE: namespace dynamic creation



Hi,

Have a look at:

http://www.dpawson.co.uk/xsl/sect2/N5536.html#d113e1164

Jeni explains this tricky issue much better than most.

cheers
andrew 

> -----Original Message-----
> From: Tevoi Andrea [mailto:tevoi@cad.it]
> Sent: 11 October 2002 10:11
> To: xalan-j-users@xml.apache.org
> Subject: namespace dynamic creation
> 
> 
> Hi,
> 
> in my Xsl i'd like to do something like this:
> 
> <xsl:attribute name="xmlns:myprefix"><xsl:value-of 
> select="any XPath expression"/></xsl:attribute>
> 
> but for Xsl this is an error (because attribute name begin 
> with "xmlns").
> 
> How can i do? I mean: i would create a namespace dynamically 
> using an XPath expression, because I need to create (by xsl 
> transformation) a Schema like this:
> 
> <xsd:schema targetNamespace="my dynamic namespace" 
> xmlns:xsd="http://www.w3.org/2001/XMLSchema"
> xmlns:myprefix="my dynamic namespace">...
> 
> 
> 
> I've tried a solution creating a dummy attribute:
> 
> ...
> <xsl:attribute name="myprefix:dummy" 
> namespace="{$myDynamicNamespace}"/>
> ...
> 
> This solution works fine with Microsoft Xsl Parser, but 
> doesn't with Xalan (i use version 2.4).
> 
> Xalan creates the attribute, but not the namespace declaration.
> Please help me.
> 
> thanks for your attention,
> 
> Andrea Tevoi
> 
> 
> 
> ---
> Incoming mail is certified Virus Free.
> Checked by AVG anti-virus system (http://www.grisoft.com).
> Version: 6.0.394 / Virus Database: 224 - Release Date: 03/10/2002
>  
> 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.394 / Virus Database: 224 - Release Date: 03/10/2002
 

Mime
View raw message