You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@xalan.apache.org by Robert Zimmermann <rz...@webde-ag.de> on 2003/12/01 12:25:31 UTC

RE: XalanC: transform xml wich is in an default-namespace

Thanks a lot, that works


> -----Original Message-----
> From: Gary L Peskin [mailto:garyp@firstech.com]
> Sent: Friday, November 28, 2003 6:50 PM
> To: xalan-dev@xml.apache.org
> Subject: RE: XalanC: transform xml wich is in an default-namespace
> 
> 
> XSLT requires that the patterns in the match attribute be namespace
> qualified.
> 
> Try:
> 
>   <xsl:template match="/d:FOO" xmlns:d="http://www.foo.org/">
> 
> HTH,
> Gary
> 
> > -----Original Message-----
> > From: Robert Zimmermann [mailto:rz@webde-ag.de] 
> > Sent: Friday, November 28, 2003 9:43 AM
> > To: xalan-dev@xml.apache.org
> > Subject: XalanC: transform xml wich is in an default-namespace
> > 
> > 
> > Hi,
> > 
> > I have an xml-source wich defines an default namespace in 
> > it's root element:
> > 
> > test.xml
> > 
> > <?xml version="1.0" encoding="utf-8"?>
> > <FOO xmlns="http://www.foo.org/">
> >     <TEXT>some text here</TEXT>
> > </FOO>
> > 
> > and try to transform it with this simple stylesheet:
> > 
> > test.xsl
> > 
> > <?xml version="1.0" encoding="utf-8"?> 
> > <xsl:stylesheet version="1.0" 
> > xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
> > 
> > <xsl:template match="/FOO">
> >     <xsl:text>Yes It Works</xsl:text>
> > </xsl:template>
> > 
> > </xsl:stylesheet>
> > 
> > 
> > but my template never get called, insted the default-templates run.
> > 
> > is this a bug, or did i miss something in xslt?
> > 
> > My Components are:
> > xalan 1.5
> > xerces 2.2.0
> > 
> > thanks,
> >  robert
> > 
>