Altova Mailing List Archives>Archive Index >microsoft.public.xsl Archive Home >Recent entries >Thread Prev - xsl attributes [Thread Next] Re: xsl attributesTo: NULL Date: 4/5/2006 4:40:00 PM Mike P wrote: > If this piece of code sets the bgcolor to the value of @StatusColor, > > <xsl:attribute name="bgcolor"> > <xsl:value-of select="@StatusColor" /> > </xsl:attribute> > > why doesn't replacing 'bgcolor' with 'color' or 'forecolor' set the > forecolor to the value of @StatusColor? Well you do not even show us what kind of element you are setting that attribute on. If you are generating HTML and that is a td or th cell element for instance then HTML 4 defines bgcolor as an attribute but neither color nor forecolor (<http://www.w3.org/TR/html4/present/graphics.html#adef-bgcolor>). If that is a HTML body element then the text attribute is a deprecated way to suggest the text color (<http://www.w3.org/TR/html4/struct/global.html#edef-BODY>). So you are asking in the wrong group if this is an HTML problem, XSLT simply generates some result tree and serializes that, whether bgcolor or color or forecolor has any meaning depends on the HTML or XML you generate. Nowadays if that is HTML then you should generate the proper structure with HTML and suggest the wanted presentation with CSS, see the CSS 2.1 specification <http://www.w3.org/TR/CSS21/> or try a CSS tutorial. -- Martin Honnen --- MVP XML http://JavaScript.FAQTs.com/ | ||||||
| Company | Legal | Press | Partners | Careers | Sitemap | Contact Us | Altova Blog | Mobile | Full Site | |||
|
