W3C home > Mailing lists > Public > www-style@w3.org > May 2006

Re: [CSS2 counters] Is it possible to evaluate a value inside CSS?

From: Daniel MD <danielmendes@im-thinking.com>
Date: Tue, 16 May 2006 13:23:42 +0100
Message-Id: <7.0.1.0.2.20060516132328.0224a050@im-thinking.com>
Message-Id: <7.0.1.0.2.20060516131005.02241cc0@im-thinking.com>
To: www-style@w3.org

At 21:57 15-05-2006, you wrote:
>Why not to define
>
>li:nth-child( 1 ) ... {  background-image: url(1.gif);  }
>li:nth-child( 2 ) ... {  background-image: url(2.gif);  }
>li:nth-child( 3 ) ... {  background-image: url(3.gif);  }
>
>and so forth? A bit noisy but will work...
>
>
>Andrew Fedoniouk.
>http://terrainformatica.com

I know that works but that is not very fun, nor a trick ;)

What i wanted was to use the counter value and have the values 
increment automatically and evaluate to a string that in turn is a 
image tag, that way we can have different images for different 
bullets and not have to do all that CSS code :)   
Received on Tuesday, 16 May 2006 12:23:04 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 27 April 2009 13:54:45 GMT