W3C home > Mailing lists > Public > www-validator@w3.org > April 2007

Re: [ANN] Beta test of the W3C Markup Validator (0.8.0 beta 1)

From: Sam Ruby <rubys@intertwingly.net>
Date: Tue, 24 Apr 2007 13:39:29 -0400
Message-ID: <462E40D1.1090909@intertwingly.net>
To: Shane McCarron <shane@aptest.com>
CC: www-validator@w3.org

Shane McCarron wrote:
> Forgive me for chiming in late on this, but...  While I agree with the 
> following:
>> "If no Accept header field is present, then it is assumed that the
>> client accepts all media types."
>> Since the validator sends no Accept header, it should be assumed that
>> the client accepts all media types. If your rule assumes that it
>> doesn't support XHTML because of that, then isn't that a flaw in the
>> rule?
> That's fine.  Is there a clever mod_rewrite rule we can suggest for 
> people that means "when you see no accept header, do *this* for *that* 
> type of request" ?  I don't speak mod_rewrite that well.

The following will rewrite everything (.*), you might want to scope the 
rewrite rule to (\.html) instead:

RewriteCond %{HTTP_ACCEPT} ^$
RewriteRule .* - [T=application/xhtml+xml;charset=utf-8]

- Sam Ruby
Received on Tuesday, 24 April 2007 17:39:50 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 1 March 2016 14:17:51 UTC