rexwashburn
1/27/2019 - 12:20 PM

GET・POSTパラメータ取得 1

#!/usr/local/bin/python3.4
# coding:utf-8
import cgi

print("Content-Type: application/json; charset=UTF-8\r\n")

form = cgi.FieldStorage()
# name を取得 値がない場合は none
name = form.getvalue('name', 'none')
print(name)