Re: [xsl] A beef with XSLT Sometimes too complicated

Subject: Re: [xsl] A beef with XSLT Sometimes too complicated
From: Nic James Ferrier <nferrier@xxxxxxxxxxxxxxxxxxxx>
Date: Fri, 14 Jul 2006 10:16:19 +0100
David Carlisle <davidc@xxxxxxxxx> writes:

>> Is there a cleaner / simpler way to do this?  Any chance you can do
>> this in one line?
>
> In xslt2:
>
> <xsl:variable name="bg_img" select="if(normalize-space($all_vars))
>  then 'background_bright' else 'background_faded'"/>

I hate the idea of 2 'if's in a language.

IMHO that makes it even more complicated.

-- 
Nic Ferrier
http://www.tapsellferrier.co.uk   for all your tapsell ferrier needs

Current Thread