seisobs-webapp/wsgi/showEnv.py

19 lines
621 B
Python

def application(environ, start_response):
"""
Function application - Wrapper to process wsgi request
:param environ: contains information on the wsgi environment
:type environ: dict
:param start_response: function to process response header by the wsgi server
:type start_response: function
:return: response to be sent to the client by the wsgi server
:rtype: list
:version: v1.0 (2021-10-27)
"""
from cgi import FieldStorage
form = FieldStorage(fp=environ['wsgi.input'], environ=environ)
start_response('200 OK', [('Content-Type', 'text/html')])
return [form]