#!/usr/bin/env python3 import cgi import cgitb import os cgitb.enable(display=0, logdir=os.getcwd()) print('Content-Type: text/plain') print() form = cgi.FieldStorage() email = form.getvalue('name') email = form.getvalue('email') with open('anmälningar.csv', 'a') as f: print((name, email), file=f)