W3C home > Mailing lists > Public > www-style@w3.org > February 2008

Re: [CSS21] The grammar of url() token

From: Christof Hoeke <csad7@t-online.de>
Date: Thu, 28 Feb 2008 21:19:20 +0100
Message-ID: <47C71748.2010408@t-online.de>
To: fantasai <fantasai.lists@inkedblade.net>
CC: "Philip Taylor (Webmaster)" <P.Taylor@Rhul.Ac.Uk>, Bert Bos <bert@w3.org>, www-style@w3.org

fantasai wrote:
> 
> Philip Taylor (Webmaster) wrote:
>>
>>
>>
>> Bert Bos wrote:
>>
>>  > But to answer the question about the comma: We wanted to preserve the
>>  > possibility of adding arguments to the url(), e.g.,
>>  > url(http://example.com/,cookie=hfdh455f).
>>
>> That is (IMHO) a horribly ugly syntax; the delimiter
>> needs to be tall if it is to be obvious, and a semi-colon
>> would be far clearer to the reader than a comma (which
>> actually looked like a period in the e-mail, and only
>> became a clear comma when I replied using a monospaced
>> font).
> 
> A better future extension would be URL fallbacks, imo:
> 
>   background-image: url(image.svg, image.png, image.gif, image.jpg);
> 
> ~fantasai

As I think this feature would indeed be very useful the comma AFAIK is a 
special character in an URI (http://www.faqs.org/rfcs/rfc2396.html 
Appendix A) and so theroretically would clash with the above syntax, 
would it not?

The only simple alternative I could think of that would fit into the 
existing CSS conventions would be a simple space separated list which 
may even be a nice alternative anyway:

	background-image: url(image.svg image.png image.gif image.jpg);

Any opinions?
christof
Received on Thursday, 28 February 2008 20:21:00 GMT

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