From: Nic Ferrier <nferrier@tapsellferrier.co.uk>
Cc: emacs-devel@gnu.org
Subject: Re: Do you understand this?
Date: Sun, 06 Mar 2005 23:12:52 +0000 [thread overview]
Message-ID: <87psycjrm3.fsf@tapsellferrier.co.uk> (raw)
In-Reply-To: <m1D84Iy-0004RGC@rattlesnake.com> (Robert J. Chassell's message of "Sun, 6 Mar 2005 22:32:56 +0000 (UTC)")
"Robert J. Chassell" <bob@rattlesnake.com> writes:
> Accept: text/plain;
> q=0.5, text/html, text/x-dvi;
> q=0.8, text/x-c
>
> If sent in an HTTP request for a resource /fred the above Accept
> headers tells the server that the user will ideally accept /fred as an
> HTML document or a text/x-c document.
>
> I do not understand.
>
> Am I right in formatting the statement such that semi-colons have a
> higher precedence than commas?
Yes. A media-type is a major-type / minor-type plus an optional list
of parameters which are separated from themselves and the major/minor
type info by semi-colons, eg:
text/plain; charset=utf-8; otherparam=xxx; q=0.5
> If that is the case, then the above sequency looks to me to favor
>
> * text/x-c as the highest priority;
>
> * text/html, text/x-dvi both equally as the second priorty; and,
>
> * text/plain as the third, lowest priority.
No quality specifier indicates priority 1.0 (the highest).
> But I do not know anything about this and would like to be told more.
>
> An alternative formatting is that semi-colons precede q settings, and
> that if a format lacks a q setting, it has the highest priority.
>
> Thus, the above could be formatted like this
>
> Accept: text/plain; q=0.5,
> text/html, text/x-dvi; q=0.8,
> text/x-c
My original was cut straight out of rfc2616 and is formatted badly (I
think to empahsise the syntax over any arbritary textual ordering).
A more sensible textual rendering would look like this:
Accept: text/plain; q=0.5,
text/html; q=1.0,
text/x-dvi; q=0.8,
text/x-c; q=1.0
Hope that's clearer.
prev parent reply other threads:[~2005-03-06 23:12 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-03-06 19:11 Do you understand this? Richard Stallman
2005-03-06 20:44 ` Nic Ferrier
2005-03-06 22:32 ` Robert J. Chassell
2005-03-06 22:58 ` Andreas Schwab
2005-03-06 23:05 ` Jason Rumney
2005-03-07 15:37 ` Robert J. Chassell
2005-03-07 17:10 ` Jason Rumney
2005-03-07 23:46 ` Robert J. Chassell
2005-03-08 0:34 ` Nic Ferrier
2005-03-08 18:41 ` Robert J. Chassell
2005-03-09 16:58 ` Richard Stallman
2005-03-06 23:12 ` Nic Ferrier [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87psycjrm3.fsf@tapsellferrier.co.uk \
--to=nferrier@tapsellferrier.co.uk \
--cc=emacs-devel@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).