Ending slash in url yielding source doc. display??

Peter C. Gorman pcgorman at facstaff.wisc.edu
Fri Jan 9 14:10:22 EST 1998


Sara Tompson writes:

>When one types in/uses a bookmark, for the urls for at least two of our
>pages, when the urls have ending slashes (e.g.
>http://fnalpubs.fnal.gov/index.html/) the resulting display on the browser
>is the SOURCE DOCUMENT, i.e. the html-tagged text file.
>This happens using Netscape on the following platforms:  Mac OS, Win NT,
>and UNIX.  But it does not happen ALL the time!
>
>A UNIX support guy says the end slashes are the problem.  That could well
>be.  But they were never a problem on previous versions of the OS on our
>Sun station.

It depends. If index.html is a file, you should definitely not have the
trailing slash. If index.html is a directory, you should include the
trailing slash. The slash indicates that the preceding text is either a
host name or a directory name. My guess is that the browser thinks it's
getting a directory listing in reponse to the request for that URL, rather
than a file of type text/html, so it dumps it to the screen without parsing
it for markup. It may be that in your previous environment the server
caught the error and returned a file with the appropriate MIME type.

Hope this helps,

PG
_______________________________
Peter C. Gorman
University of Wisconsin
General Library System
Automation Services
pcgorman at facstaff.wisc.edu
(608) 265-5291




More information about the Web4lib mailing list