[Zope-dev] VirtualHostFolder Product (similar to Site objects)

Lalo Martins lalo@webcom.com
Fri, 24 Sep 1999 06:15:40 -0300


Of course I had to blow it up.

> +            if len(host_info)=1

The correct patch is:

--- Remapper.py.orig	Tue Sep 21 22:12:33 1999
+++ Remapper.py	Fri Sep 24 05:50:26 1999
@@ -80,7 +80,12 @@
         # try HTTP/1.1 Host header identification first
         http_host = request.get('HTTP_HOST')
         if http_host != None:
-            requestedSite,requestedPort=string.split(http_host,':')
+            host_info=string.split(http_host,':')
+ 	    requestedSite=host_info[0]
+            if len(host_info)==1:
+		requestedPort='80'
+            else:
+		requestedPort=host_info[1]
             #print "remap- requestedSite %s" % requestedSite
             try:
                 path_prefix=self.root[requestedSite]

[]s,
                                               |alo
                                               +----
--
      I am Lalo of deB-org. You will be freed.
                 Resistance is futile.

http://www.webcom.com/lalo      mailto:lalo@webcom.com
                 pgp key in the web page

Debian GNU/Linux       --        http://www.debian.org