Cleaned up code, removed HTML return on POST.