Hello Zopistas,
I have updated the HOW-TO: Serve PHP/Perl within Zope with a nifty
alternative by Joseph Wayne Norton. His suggestion allows PHP to call Zope
methods. Check it out at www.zope.org/Members/Mamey/PHP.
The methods presented in the HOW-TO still have some deficiencies with
regards to
I had to dig a level deeper to support phorum (www.phorum.org), a PHP
message board app. Here's my update to handle cookies, redirection, POST
variables, and relative links. I'm new to python, so if I've done anything
awkwardly, please let me know the more elegant way.
First, a patch to Client.
Got authorization to work!
First, another patch to Client.py to raise 'Unauthorized' when 401 is
returned by PHP/Perl:
after line that starts with
if ec==200
add
if ec==401:
raise 'Unauthorized'
Second, numerous changes to the external method that makes the request and
receives t
oops!
that should be
username, password = req._authUserPW()
___
Zope maillist - [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope
** No cross posts or HTML encoding! **
(Related lists -
http://lists.zope.org/mailman/listinfo/
oops, again :-(
headers = {}
if req.environ.has_key('HTTP_COOKIE'):
headers['Cookie'] = req.environ['HTTP_COOKIE']
if req.environ.has_key('HTTP_USER_AGENT'):
headers['User-Agent'] = req.environ['HTTP_USER_AGENT']
Also on my member page - http://zope.org/Members/billw/
Last bug. Promise.
# user might not have signed in yet
try:
username, password = req._authUserPW()
except:
username = password = None
___
Zope maillist - [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope
** No