- From: Bjoern Hoehrmann <derhoermi@gmx.net>
- Date: Tue, 17 Apr 2001 23:17:34 +0200
- To: Terje Bless <link@tss.no>
- Cc: www-validator@w3.org
* Terje Bless wrote: >> * don't claim to be redirected from http://host or http://host:80/ to >> http://host/ -> uses URI::eq() > >But lack of a trailing slash _is_ a redirect! http://host and http://host/ are equivalent, the trailing slash may be omitted here, see RFC 2616. What you mean is http://www.w3.org/TR redirects to http://http://www.w3.org/TR/ URI::eq returns true for the first case, false for the second. >> * un-break /referer;ss etc. -> lets CGI.pm parse the trailing part > >Hmm, this was dropped back when we first moved to CGI.pm partially to >discourage that syntax as it's indescribably ugly IMO. Wanna "think aloud" >about why you think it's a good idea? E.g. if you want to present the outline of the document, specify a doctype, show the source, etc.pp. >> * the line >> >> $q->param('uri', $q->param('uri') . '/') >> unless $q->param('uri') =~ m(/); >> >> is useless, $q->param('uri') always contains a '/' or the '/' isn't >> needed anywhere -> deleted > >http://foo.com --> http://foo.com/ Yes, that trailing slash can be omittet, I don't see any good reason to add the slash here, but if you want to do so, please use URI->new( $uri )->canonical The above can be replaced with URI::Heuristic by the way. In general, I'd better use one URI object instead of all those $q->param('uri') calls. >>other issues >> >> * prevent caching of /referer documents >> -> what about using a HTTP::Headers object for the header instead of >> a simple string? > >I'm not following you here. Where do you want to use HTTP::Header, why, >how, and for what? Currently the header is saved like my $header = <<"EOF"; Content-Type: text/html; charset=utf-8 ... and printed where needed, if we want to add caching headers, it would be better to use a HTTP::Headers object here instead of a plain scalar. >> * what about using a XML validator without the limitations of nsgmls >> to validate XML documents? > >Such as? :-) http://www.stg.brown.edu/service/xmlvalid/dist/ http://www.cogsci.ed.ac.uk/~richard/rxp.html XML::LibXML, XML::Xerces, etc. >>- Or add a "show source iff errors" option? >>+ Or add a "show source if errors" option? > >Not sure this is a typo. "iff" == "if and only if" Well, this wasn't covered by any of the 3 dictionaries if searched through... -- Björn Höhrmann { mailto:bjoern@hoehrmann.de } http://www.bjoernsworld.de am Badedeich 7 } Telefon: +49(0)4667/981028 { http://bjoern.hoehrmann.de 25899 Dagebüll { PGP Pub. KeyID: 0xA4357E78 } http://www.learn.to/quote/
Received on Tuesday, 17 April 2001 17:16:42 UTC