[Zope] RewriteRules problems and broken image links
Harry
mail-zope@fizbin.com
Tue, 16 Nov 1999 23:09:32 -0800
Here's the issue I'm dealing with:
I have an installation, linux box, running apapche, with Zope and PCGI
installed.
The box is running several virtual servers under the main IP, using apache's
VirtualHost directive.
One of them is my Zope enabled Squishdot site.
I have a Squishdot installation configured, and it's working. I needed
specific URLs and Paths to work, so Jeff Rush helped me out with some
rewriterules that worked -- about 90%.
Here's where things get tricky:
My site is reachable under:
http://www.ourlife.com/OurLife/
as well as
http://www.ourlife.com/OurLife
First of all, the two Zope provided images at the bottom of the page are
broken. Next, if you go to the manage admin screen"
http://www.ourlife.com/OurLife/manage
The proper screen comes up, but ALL of the image links are broken.
Upon inspection of the HTML source, it appears that all local (to Squishdot)
links are properly resolved, while all Zope specific links are missing a
part of the URL pointing to the right directory, e.g.:
img src="http://www.ourlife.com/p_/ZopeButton
instead of
img src="http://www.ourlife.com/Zope/p_/ZopeButton
Where the graphics reside.
Now, going to:
http://www.ourlife.com/Zope/OurLife/
http://www.ourlife.com/Zope/OurLife/manage
and everything wroks exactly like it should, except that this is not the URL
I want it to be reachable at.
I'll include my RewriteRules at the end of this, but it appears that I'm
either missing something, or am failing to specify a rule that addresses the
Zope specific items, or something else (of course.
Either way, I've raked my brain over this weekend, and hopefully someone out
there has a better grip on this kind of situation than me, and can help out
here...please.
The rewriteRules are INSIDE the VirtualHost directive, and are as follows:
RewriteEngine on
RewriteRule ^/cgi-bin/(.*) /home/httpd/cgi-bin/$1
[e=HTTP_CGI_AUTHORIZATION:%1,t=application/x-httpd-cgi,l]
RewriteCond %{HTTP:Authorization} ^(.*)
RewriteRule ^/OurLife(.*) /home/httpd/cgi-bin/Zope/OurLife$1
[e=HTTP_CGI_AUTHORIZATION:%1,t=application/x-httpd-cgi,l
RewriteCond %{HTTP:Authorization} ^(.*)
RewriteRule ^/Zope(.*) /home/httpd/cgi-bin/Zope$1
[e=HTTP_CGI_AUTHORIZATION:%1,t=application/x-httpd-cgi,l]
RewriteRule ^/(.*) /home/ourlife/$1 [l]
If anything else is needed in the pursuit to fix this, just let me know, and
any solution will be welcomed with open arms...
Harry