def application(environ, start_response):
    output = ['<pre>']
output.append(pformat(environ))
output.append('</pre>')
output.append('<form method="post">')
output.append('<input type="text" name="test">')
output.append('<input type="submit">')
output.append('</form>')
if environ['REQUEST_METHOD'] == 'POST':
    output.append('<h1>FORM DATA</h1>')
output.append(pformat(environ['wsgi.input'].read()))
Python POST data using mod_wsgi