From: Guido van Rossum Date: Mon, 4 Sep 2000 15:55:31 +0000 (+0000) Subject: For this server to work on Windows, directories should use "/" as the X-Git-Tag: v2.0b1~31 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=1d105d15d38578f9a2877826cc142e6c21bfdc55;p=python For this server to work on Windows, directories should use "/" as the separator in the href, not os.sep. Added a tag to directory listings. Bumped version to 0.5. --- diff --git a/Lib/SimpleHTTPServer.py b/Lib/SimpleHTTPServer.py index 8a7775856c..4cfedbc9fe 100644 --- a/Lib/SimpleHTTPServer.py +++ b/Lib/SimpleHTTPServer.py @@ -6,7 +6,7 @@ and HEAD requests in a fairly straightforward manner. """ -__version__ = "0.4" +__version__ = "0.5" import os @@ -99,6 +99,7 @@ class SimpleHTTPRequestHandler(BaseHTTPServer.BaseHTTPRequestHandler): return None list.sort(lambda a, b: cmp(a.lower(), b.lower())) f = StringIO() + f.write("<title>Directory listing for %s\n" % self.path) f.write("

Directory listing for %s

\n" % self.path) f.write("
\n