mirror of
https://github.com/Team-Resurgent/XBMC4Xbox.git
synced 2026-08-15 11:18:13 -07:00
If ever adding the XBMC4Xbox source to GitHub use "git add -f -A" or it wont add all the files.
23 lines
470 B
Python
23 lines
470 B
Python
#!/usr/bin/env python
|
|
|
|
"""CGI test 2 - basic use of cgi module."""
|
|
|
|
import cgitb; cgitb.enable()
|
|
|
|
import cgi
|
|
|
|
def main():
|
|
form = cgi.FieldStorage()
|
|
print "Content-type: text/html"
|
|
print
|
|
if not form:
|
|
print "<h1>No Form Keys</h1>"
|
|
else:
|
|
print "<h1>Form Keys</h1>"
|
|
for key in form.keys():
|
|
value = form[key].value
|
|
print "<p>", cgi.escape(key), ":", cgi.escape(value)
|
|
|
|
if __name__ == "__main__":
|
|
main()
|