Altova Mailing List Archives>Archive Index >microsoft.public.xsl Archive Home >Recent entries >Thread Prev - Re: style attribute sets? >Thread Next - Re: style attribute sets? Re: style attribute sets?To: NULL Date: 1/7/2006 10:07:00 AM "Egbert Nierop (MVP for IIS)" <egbert_nierop@n...> wrote in message news:OBLG7l2EGHA.3348@T...... > > "Joe Fawcett" <joefawcett@n...> wrote in message > news:enENoovEGHA.1240@T...... >> "Egbert Nierop (MVP for IIS)" <egbert_nierop@n...> wrote in >> message news:%23DsexAvEGHA.1540@T...... >>> >>> "Joe Fawcett" <joefawcett@n...> wrote in message >>> news:OjNMljqEGHA.1088@t...... >>>> "Egbert Nierop (MVP for IIS)" <egbert_nierop@n...> wrote in >>>>> >>>>>> -- >>>>>> Joe Fawcett - XML MVP >>>>>> >>>>>> https://mvp.support.microsoft.com/profile=8AA9D5F5-E1C2-44C7-BCE8-8741D22D17A5 >>>>>> >>>>> >>>> I don't see any style information... >>> >>> sorry for misunderstanding. >>> >>> This does not come from XML. >>> >>> Let me just describe what I want, it is quite simple. >>> I have a html table where even rows get a light-grey background and >>> uneven rows get an other color. >>> >>> I know this can be done while avoiding the style= property, but I want >>> to respect some HTML level- conformity. >>> >>> >> Okay, but I don't understand your problem, either set the style attribute >> to be whatever you wish or assign a class and use css. >> It's not two attributes, it's one attribute with a string value that's >> interpreted by the browser as a collection. > > It's is more attributes because in this sample I would modify the color > per line with a different color. > > ps: I am very good at HTML so I know what are the possibilities using CSS > but not through xsl. > >> <xsl:template match="/"> >> <table><tbody><xsl:apply-templates select="ElementForTableRow" >> /></tbody></table> >> </xsl:match> >> >> <xsl:template match="ElementForTableRow"> >> <tr><td style="width:20;left-margin:10px"><xsl:value-of >> select="ElementForTableCell" /></td></tr> >> </xsl:template> >> >> -- >> Joe >> > Okay but as I don't know how you decide the colour it's difficult. If you want to send me an example XML and example HTML output with the logic of how you decide the style for each row I'll have another go. My email is on my MVP profile. -- Joe Fawcett - XML MVP https://mvp.support.microsoft.com/profile=8AA9D5F5-E1C2-44C7-BCE8-8741D22D17A5 | ||||||
| Company | Legal | Press | Partners | Careers | Sitemap | Contact Us | Altova Blog | Mobile | Full Site | |||
|
