Thanks for the code.
>class FormContent:
> def __init__(self):
> if os.environ['QUERY_STRING'] != '':
> self.qs = os.environ['QUERY_STRING']
> else:
> self.qs = sys.stdin.readline()
But, is this bit safe as far as the http specification is concerned?
I'm no expert, but as I understood it, shouldn't it be ...
if os.environ['REQUEST_METHOD'] == 'POST':
self.qs = sys.stdin.read(int(os.environ['CONTENT_LENGTH']))
else:
self.qs = os.environ['QUERY_STRING']
... or similar.
Thanks again,
Neil.