Re: Bug in url() parsing when url() contains a data URL (data:) without quotes

On Wed, 30 May 2012, Bert Bos wrote:

> The validator seems to try and check the syntax of URLs inside url() to
> some extent. However, it doesn't do that correctly/consistently:
>
> 1) It seems the validator doesn't know about data URLs and gives errors
> for URLs such as this one:
>
> a:before {
> content:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABAQAAAAA3bvkkAAAACklEQVQImWNoAAAAggCByxOyYQAAAABJRU5ErkJggg==)
> }

It's parsed as
( [ "!", "#", "$", "%", "&", "*"-"[", "]"-"~" ] | <NONASCII> | <ESCAPE> )*
So the error is not in the parsing section, but if it doesn't work, then 
it's still a bug :)

>
> 2) It doesn't give the same error when the URLs is quoted. The following
> has the same data URL, but is considered valid:
>
> a:before {
> content:url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABAQAAAAA3bvkkAAAACklEQVQImWNoAAAAggCByxOyYQAAAABJRU5ErkJggg==")
> }
>
>
>
> Bert
>

-- 
Baroula que barouleras, au tiƩu toujou t'entourneras.

         ~~Yves

Received on Monday, 4 June 2012 14:49:29 UTC