W3C home > Mailing lists > Public > public-respimg@w3.org > September 2013

Re: srcN - Alternative to picture and srcset

From: Tab Atkins Jr. <jackalmage@gmail.com>
Date: Fri, 27 Sep 2013 09:43:34 -0700
Message-ID: <CAAWBYDBA7fOLHgTJEhMWn3AYTewrF2pGC5wwvVq5YuVCsuDEpQ@mail.gmail.com>
To: Shane Hudson <Shane@shanehudson.net>
Cc: Marcos Caceres <marcos@marcosc.com>, "public-respimg@w3.org" <public-respimg@w3.org>, Robin Berjon <robin@w3.org>
On Fri, Sep 27, 2013 at 3:51 AM, Shane Hudson <Shane@shanehudson.net> wrote:
> I quite like where Tab is going with this. I wonder though, would it be
> possible to have multiple srcs instead of numbering them? It feels kind of
> hacky. I'm pretty sure that browsers (both current and legacy) only take the
> first src in an img?

No, you can't have multiple attributes of the same name - the HTML
parser deals with that and only takes one of them.

On Fri, Sep 27, 2013 at 4:14 AM, Attiks <attiks@gmail.com> wrote:
> I have to agree with Shane, it feels hacky to number them, also if you want
> to remove one later, you'll have a gap, which does not look nice and no idea
> how it's going to be handled.

Yeah, gaps don't look nice, but they're handled fine - the algorithm
collects all of the srcN attrs and sorts them by index (step 4), so
gaps are just skipped over.

> Maybe it is an option to separate all of them into one src using for example
> a ";"

I'm already using a semicolon and a comma; I think another level of
separator would get really confusing.  ^_^

Received on Friday, 27 September 2013 16:44:21 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 20:12:40 UTC