[Zope] Re: Re: [ZOPE] Newbie Zope step 2.

Michael Bradbery mbradbery@interconnect.com.au
Wed, 01 Sep 1999 14:31:08 EST


Thanks Martijn and Thierry,

Neither of your solutions worked, but they did give me some ideas and I now 
have a better idea of the mechanics of my problem...

Thierry, my main.dtml is different to yours... and Martijn,
   ^/Zope(/.*) /home/httpd/cgi-bin/Zope.cgi$1 didn't work... but, thinking 
with my fingers, looking at the main.dtml (it is burried so deep in the 
subdirectories....  I doubt I would have found it myself) I discovered that 
I could add pages, if I went directly to the address: 
http://linus/Zope/manage_addDTMLDocumentForm




I could change the main.dtml so that I am sent to these type  addresses, but 
I feel I will run into other trouble later on when I try external methods.

The way I understand it at the moment, what the rewrite rule is trying to do 
is to turn:

http://linus/Zope/?%3Amethod=manage_addDTMLDocumentForm

into

http://linus/Zope.cgi?%3Amethod=manage_addDTMLDocumentForm

which will then redirect to

http://linus/Zope/manage_addDTMLDocumentForm


I feel very close to a solution now... and at least I can build some Zope 
pages while I am stumped.

Thanks again....

I will go away for a think and try again tonight or tomorrow.

MGB.

>From: Martijn Pieters <mj@antraciet.nl>
>To: Thierry <thierry@glisco.it>, zope@zope.org
>CC: mgb58@hotmail.com
>Subject: Re: [Zope] Re: Re: [ZOPE] Newbie Zope step 2.
>Date: Tue, 31 Aug 1999 16:36:45 +0200
>
>At 16:11 31/08/99 , Thierry wrote:
>>Hi,
>>
>>Put a slash in the file <zope directory>/lib/python/OFS/main.dtml, at line 
>>9.
>>
>>
>><FORM ACTION="<!--#var URL1-->/" METHOD="POST">
>>                                                                   ^^^
>>instead of
>>
>><FORM ACTION="<!--#var URL1-->" METHOD="POST">
>>
>>
>>Your Rewrite Rules are correct :
>>
>>RewriteEngine On
>>RewriteLog /new/usr/apache/logs/rewrite_log
>>#RewriteLogLevel 9
>>
>>RewriteCond %{HTTP:Authorization}  ^(.*)
>>RewriteRule ^/Zope/(.*) /home/httpd/cgi-bin/Zope.cgi/$1 \
>>[e=HTTP_CGI_AUTHORIZATION:%1,t=application/x-httpd-cgi,l]
>>
>>If you use
>>
>>^/Zope(.*) /home/httpd/cgi-bin/Zope.cgi$1
>>
>>any URL starting with Zope will match which is not what you want.
>>If you use this rule :
>>
>>     http://my.site.com/Zope_any_word _you_like
>>
>>will be converted to :
>>
>>  home/httpd/cgi-bin/Zope.cgi_any_word_you_like
>>
>>which fails miserably, because there is not a CGI with that name.
>
>I don't see this as a problem... either way it is an error.
>
>Its just that I saw a similar problem a while back (I can't find the email
>anymore) that was solved tweaking the rewrite rule. My rewrite works just
>fine right now.
>
>Maybe if you tried:
>
>    ^/Zope(/.*) /home/httpd/cgi-bin/Zope.cgi$1
>
>

______________________________________________________
Get Your Private, Free Email at http://www.hotmail.com