This is the mail archive of the
xsl-list@mulberrytech.com
mailing list .
RE: illegal xhtml attributes?
- To: <xsl-list at lists dot mulberrytech dot com>
- Subject: RE: [xsl] illegal xhtml attributes?
- From: "Michael Kay" <mhkay at iclway dot co dot uk>
- Date: Mon, 2 Apr 2001 14:51:58 +0100
- Reply-To: xsl-list at lists dot mulberrytech dot com
> <xsl:attribute name="width">
> <xsl:value-of select="$imagewidth"/>
> </xsl:attribute>
> <xsl:attribute name="height">
> <xsl:value-of select="$imageheight"/>
> </xsl:attribute>
> <xsl:attribute name="alt">
> <xsl:value-of select="$imagealt"/>
> </xsl:attribute>
> <out:attribute name="src">
> <out:value-of select="$image"/>
> </out:attribute>
> <xsl:if test="$reset='true'">
> <xsl:attribute name="alt">
> <xsl:value-of select="'Reset'"/>
> </xsl:attribute>
> </xsl:if>
>
It might be that your XSLT processor (have you told us which one you're
using?) is objecting to outputting two attributes with the same name ("alt"
appears twice).
It shouldn't - this is quite OK in XSLT, the second takes precedence.
You seem to like typing; what's wrong with
<img width="{$imagewidth}" height="{$imageheight}" ...>
Mike Kay
Software AG
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list