Re: Adaptive images

Karl Dubost, Mon, 30 May 2011 10:24:37 -0400:
> 
> Le 30 mai 2011 à 09:43, Dominique Hazael-Massieux a écrit :
>> But one aspect that remains difficult to manage in such an approach is
>> handling of content images.
> 
> :)
> 
> one technique which is also used currently (and not satisfying) is 
> 
http://www.broken-links.com/2011/02/21/using-media-queries-in-the-real-world/

> <div class="img" data-height="100" data-src="image.png" data-width="100" />

If browsers developed better support for CSS generatd and replaced 
content, then why could not media queries be used? For example:

@media (min-width:500px) {img#image{content:url(highrez.jpeg)}}

 
> Another possibility using javascript and data-* API [1]
> 
>  <img src="lowres" data-src="highres" alt="boo"/>

The very idea about "adaptive images" seems related to the @fullsize 
attribute proposal. @fullsize was however rejected by the editor, who 
instead listed a range of alternative solutions, includig 
data-fullsize: 
 http://www.w3.org/Bugs/Public/show_bug.cgi?id=12365#c11

-- 
Leif Halvard Silli

Received on Monday, 30 May 2011 22:03:36 UTC