Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 14 Dec 1998 17:08:11 +0100
From:      Wolfram Schneider <wosch@cs.tu-berlin.de>
To:        Dag-Erling Smorgrav <des@flood.ping.uio.no>, Wolfram Schneider <wosch@panke.de.freebsd.org>
Cc:        Steve Price <sprice@hiwaay.net>, wosch@FreeBSD.ORG, jkh@FreeBSD.ORG, freebsd-bugs@FreeBSD.ORG
Subject:   Re: misc/8038
Message-ID:  <19981214170811.A1176@freno.cs.tu-berlin.de>
In-Reply-To: <xzpd85m7qqo.fsf@flood.ping.uio.no>; from Dag-Erling Smorgrav on Mon, Dec 14, 1998 at 03:17:03PM %2B0100
References:  <19981212201923.B4451@panke.de.freebsd.org> <Pine.OSF.4.02.9812131208060.4086-100000@fly.HiWAAY.net> <19981213200438.A627@panke.de.freebsd.org> <xzpd85m7qqo.fsf@flood.ping.uio.no>

next in thread | previous in thread | raw e-mail | index | archive | help
On 1998-12-14 15:17:03 +0100, Dag-Erling Smorgrav wrote:
> Wolfram Schneider <wosch@panke.de.freebsd.org> writes:
> > Homepages - e.g. http://www.freebsd.org - does not require a trailing slash. 
> 
> Yes they do. Please read RFC1738. URLs such as the one above lack the
> (non-optional) document part.

<grumel>
I read now the RFC1738 and found 3 paragraphs which
says the "/" may also be omitted.
</grumel>

RFC1738

[...]
3.1. Common Internet Scheme Syntax

   While the syntax for the rest of the URL may vary depending on the
   particular scheme selected, URL schemes that involve the direct use
   of an IP-based protocol to a specified host on the Internet use a
   common syntax for the scheme-specific data:

        //<user>:<password>@<host>:<port>/<url-path>

   Some or all of the parts "<user>:<password>@", ":<password>",
   ":<port>", and "/<url-path>" may be excluded.  The scheme specific
   data start with a double slash "//" to indicate that it complies with
   the common Internet scheme syntax. The different components obey the
   following rules:
[...]
3.3. HTTP

   The HTTP URL scheme is used to designate Internet resources
   accessible using HTTP (HyperText Transfer Protocol).

   The HTTP protocol is specified elsewhere. This specification only
   describes the syntax of HTTP URLs.

   An HTTP URL takes the form:

      http://<host>:<port>/<path>?<searchpart>;

   where <host> and <port> are as described in Section 3.1. If :<port>
   is omitted, the port defaults to 80.  No user name or password is
   allowed.  <path> is an HTTP selector, and <searchpart> is a query
   string. The <path> is optional, as is the <searchpart> and its
   preceding "?". If neither <path> nor <searchpart> is present, the "/"
   may also be omitted.

5. BNF for specific URL schemes
; HTTP

httpurl        = "http://" hostport [ "/" hpath [ "?" search ]]
hpath          = hsegment *[ "/" hsegment ]
hsegment       = *[ uchar | ";" | ":" | "@" | "&" | "=" ]
search         = *[ uchar | ";" | ":" | "@" | "&" | "=" ]

> > Adding the / to the homepage is the job of the web browser, 
> > not of the web server.
> 
> Adding the missing slash is a misfeature of popular browsers.
> 
> When it comes to missing slashes after subdirectory names (e.g.
> <URL:http://www.freebs.org/~des>), there's no way for the browser to
> know that there should be a trailing slash there. All HTTP/1.x servers
> I know of send back a code 301.
> 
> DES
> -- 
> Dag-Erling Smorgrav - des@flood.ping.uio.no
> 

-- 
Wolfram Schneider <wosch@freebsd.org> http://freebsd.org/~w/ 

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-bugs" in the body of the message



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?19981214170811.A1176>