471,850 Members | 1,062 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 471,850 software developers and data experts.

mod_python has empty POST

python 2.1.3
Debian woody
Apache 1.3.26
mod python 2.7.8

## ---- formtest.html ---- ##
<form action="/formtest.py/main" method="POST">
<input type="submit" value="go" name="action">
<input type="hidden" name="hide" value="A">
## ---- formtest.py ------ ##
import mod_python

def main(req):
form = mod_python.util.FieldStorage(req).list
vars = ''
for field in form:
if isinstance(field, mod_python.util.Field):
vars = "%s [%s] = %s" % (vars, field.name, field.value)

## ---- results ---- ##
if method is "POST" variable form is an empty list !!! <---- WRONG

if method is "GET" it's all right and I receive
a string containing : "[action] = go [hide] = A"

why I cannot access POST variables?????
... I'm bouncing like a ball ....
Jul 18 '05 #1
0 1534

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

2 posts views Thread by Arso - Italy | last post: by
3 posts views Thread by Rune Hansen | last post: by
6 posts views Thread by Little | last post: by
5 posts views Thread by bapolis | last post: by
4 posts views Thread by Ivo van der Sangen | last post: by
1 post views Thread by blbmdsmith | last post: by
4 posts views Thread by Lad | last post: by
9 posts views Thread by Rory Campbell-Lange | last post: by
reply views Thread by NeoPa | last post: by
reply views Thread by aboka | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.