W3C home > Mailing lists > Public > www-html@w3.org > November 2003

Re: AW: XHTML 2.0 and hreflang and type

From: Christian Wolfgang Hujer <Christian.Hujer@itcqis.com>
Date: Mon, 17 Nov 2003 15:10:14 +0100
To: W3C HTML List <www-html@w3.org>, www-html-request@w3.org
Message-Id: <200311171510.16548.Christian.Hujer@itcqis.com>

Hash: SHA1

Hi Lachlan,

Am Samstag, 15. November 2003 16:52 schrieb Lachlan Hunt:
>   For example, if and image was available in png, gif and jpg format,
> how could that be using the HTML 4.01 version of @type in XHTML 2.0?
> You could write, as someone suggested previously:
> <p src="image" type="image/png">
>     <p src="image" type="image/gif">
>         <p src="image" type="image/jpg">
>         Image description here...
>         </p>
>     </p>
> </p>
>   But being able to write that in a less cumbersome way, that gives the
> UA more choice about which type to get is much better, and IMHO, easier
> (for simplicity, I have excluded the q values):
> <p src="image" type="image/png, image/gif, image/jpg">Image description
> here...</p>
I'm sure you both know it, so just for those that read the thread (and 
therefor just responded to the list, not to the thread authors):
There's a difference.

I think an intelligent user agent would mulitply it's own q values with those 
from the type list to form the accept header.
Also, the same user agent might prefer jpeg and gif over png.
It's default qvalues are e.g. image/png;q=0.3, image/gif;q=1.0, 

In the case of 
> <p src="image" type="image/png">
>     <p src="image" type="image/gif">
>         <p src="image" type="image/jpg">
>         Image description here...
>         </p>
>     </p>
> </p>
the user agent preferring jpeg or gif over png will still retreive the png 
version, because image/png has become q=0.3, all others have become q=0.

While in case of
> <p src="image" type="image/png, image/gif, image/jpg">
it will try to retreive the jpg or gif version and probably receive one of 
these depending on the server's choice.

Also, I'm sure this has been mentioned yet, but I don't know when and where 
In the case of (note: this time _with_ file endings, means with uri's not 
negotiating over the content type):
<p src="image.png" type="image/png">
    <p src="image.gif" type="image/gif">
        <p src="image.jpg" type="image/jpeg">
            Image description here...
...a user agent that has a image/png q value >0.0 will retreive the PNG 
version regardless of the q values of the other content types.

I think a Note clearifying this and a note suggesting how user agents should 
treat the type attribute and compute their q values when the type attribute 
can carry a type list (which imho only makes sense when it may carry q 
values) should be published along with but independantly of XHTML 2.0 - I 
think that issue (@hreflang, @type and other attributes related to content 
negotiation) also relates to XLink and other specs.

I for my part suggest multiplication of q values and rounding them with 
round5, similar as described in RFC 2295 Appendix 19.1
Such a note should take into account RFC 2616 and RFC 2295, especially the 406 

- --
Christian Wolfgang Hujer
Geschäftsführender Gesellschafter (Shareholding CEO)
Telefon: +49  (0)89  27 37 04 37
Telefax: +49  (0)89  27 37 04 39
E-Mail: Christian.Hujer@itcqis.com
WWW: http://www.itcqis.com/
Version: GnuPG v1.2.2-rc1-SuSE (GNU/Linux)

Received on Monday, 17 November 2003 09:48:41 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 7 January 2015 15:06:06 UTC