- From: Gerald Oskoboiny <gerald@w3.org>
- Date: Sat, 21 Oct 2000 04:27:23 -0400
- To: Terje Bless <link@tss.no>
- Cc: Aaron Nielsen <pfuii@yahoo.com.au>, www-validator@w3.org
On Tue, Oct 17, 2000 at 04:49:14PM +0200, Terje Bless wrote:
> On 16.10.00 at 04:27, Aaron Nielsen <pfuii@yahoo.com.au> wrote:
>
> >I have encountered a problem using the W3C HTML Validator service.
> >
> >In attempting to upload and parse some XHTML documents, I noticed that
> >uploading files whose extensions are ".xhtml" do not parse correctly.
> >I tried a couple of files called ".xhtml" and received the following
> >error message:
>
> I haven't had a chance to wrap my head around this one yet, but I /think/
> this is a bug in the validator. It's been reported before IIRC, but no
> conclusion came of it.
>
> Anyway, if I'm not totally off base, part of the problem is that your
> browser isn't sending the correct Content-Type for these files. In your
> browser's settings (or Preferences) locate the setting for ".html" and make
> a duplicate entry for ".xhtml". The Content-Type should be "text/html"
> (without the quotes).
Yup, I think that's right.
A change I made in version 1.68 of 'check' should fix this, I think:
gerald@validator:/home/gerald/validator/httpd/cgi-bin$ cvs diff -c -r1.67 -r1.68 check
Index: check
===================================================================
RCS file: /sources/public/validator/httpd/cgi-bin/check,v
retrieving revision 1.67
retrieving revision 1.68
diff -c -r1.67 -r1.68
*** check 2000/09/29 09:19:07 1.67
--- check 2000/10/21 06:04:35 1.68
[...]
***************
*** 255,261 ****
#
# Try to extract or guess the DOCTYPE for HTML and XHTML files.
! if ($File->{Type} eq 'html' or $File->{Type} eq 'xhtml') {
($guessed_doctype, $doctype) = &check_for_doctype($File->{Content});
}
--- 256,262 ----
#
# Try to extract or guess the DOCTYPE for HTML and XHTML files.
! if ($File->{Type} ne 'xml') {
($guessed_doctype, $doctype) = &check_for_doctype($File->{Content});
}
===================================================================
--
Gerald Oskoboiny <gerald@w3.org> +1 613 261 6630
System Administrator http://www.w3.org/People/Gerald/
World Wide Web Consortium (W3C) http://www.w3.org/
Received on Saturday, 21 October 2000 04:27:24 UTC