Re: SVG Won't Scroll in Firefox 3.0.10
Martin Honnen <[email protected]> Mon, 10 Aug 2009 18:29:40 +0200
| Newsgroups | gmane.comp.mozilla.devel.svg |
|---|---|
| Organization | Liberty Development |
| Message-ID | <[email protected]> |
oliver wrote:
> Hi, that solve the issue i already use it and works, but someone have
> an idea of how to add this line using xsl transformation?
> I try tu use:
> <xsl:template match="svg:svg/@viewBox">
> <xsl:attribute name="xmlns" >
> <xsl:value-of select="'http://www.w3.org/2000/svg'"/>
> </xsl:attribute>
> </xsl:template>
> But didn't allow me to use xmlns as attribute name, any ideas?
In the XSLT data model a namespace declaration is not an attribute node,
it is a namespace node. However there is no need to create namespace
nodes in the result tree, simply create elements or attributes in the
namespace they belong to.
If you want to create an element node or attribute node in a certain
namespace then simply do that e.g.
<xsl:template match="foo">
<svg xmlns="http://www.w3.org/2000/svg">
...
</svg>
</xsl:template>
creates a result element with local name 'svg' in the SVG namespace
'http://www.w3.org/2000/svg'.
--
Martin Honnen
http://msmvps.com/blogs/martin_honnen/