[xslt] An attribute is not allowed to have the name "xmlns"


Potentially a bug was found in libxslt; unfortunately, the reporter,
Alexander Nichau, didn't come through to the this list, so he sent
the mail as an attachment to me.
Here it comes:

At xsl-list lists mulberrytech com we found a possible bug in libxslt:

>> >>
>> >><html lang="de" xml:lang="de">
>> >><xsl:attribute
>> >>name="xmlns">http://www.w3.org/1999/xhtml</xsl:attribute>

> > No, I'm sorry, but you haven't. A namespace is not an attribute, and
> > attribute is not allowed to have the name "xmlns". The spec says 
> > (section 7.1.3) "It is an error if the [name attribute] is the
> > "xmlns". If your XSLT processor accepts this stylesheet, then it 
has a bug
> > in it.

So according to the spec it should not be possible to use
<xsl:attribute name="xmlns">, because xmlns is no attribute.

DOM/XML enabled
DOM/XML API Version 20031129
libxml Version 2.6.9
HTML Support enabled
XPath Support enabled
XPointer Support enabled
Schema Support enabled
RelaxNG Support enabled

XSL enabled
libxslt Version 1.1.12
libxslt compiled against libxml Version 2.6.17
EXSLT enabled
libexslt Version 1.1.12

Thanks, Alexander

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]