|
PETER BARKER
newbarker at btinternet.com
Thu Mar 29 08:23:56 EST 2007
I came up with this:
from mod_python import apache
def handler(req):
req.content_type = 'text/plain'
req.add_common_vars()
req.write('IP address of requester is ' + req.subprocess_env['REMOTE_ADDR']);
return apache.OK
After reading the page http://www.modpython.org/live/current/doc-html/pyapi-mprequest-mem.html
Hope this helps,
Pete
Olaf Stein <steino at ccri.net> wrote:
Hi All,
Is there any built in function in mod_python to obtain the remote IP
address. Or any other way?
Thanks
Olaf
_______________________________________________
Mod_python mailing list
Mod_python at modpython.org
http://mailman.modpython.org/mailman/listinfo/mod_python
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mm_cfg_has_not_been_edited_to_set_host_domains/pipermail/mod_python/attachments/20070329/74aad17e/attachment.html
|