struct event* e;

e = event_create();
cgiFormInteger("eventno", &e->event_no, 0);
cgiFormStringNoNewlines("name", e->name, 80);
cgiFormStringNoNewlines("location", 
                        e->location, 80);

/* Processing date fields */
cgiFormInteger("beginyear", 
               &e->event_begin->year, 0);
cgiFormInteger("beginmonth", 
               &e->event_begin->month, 0);
cgiFormInteger("beginday", &e->event_begin->day, 0);
cgiFormInteger("endyear", &e->event_end->year, 0);
cgiFormInteger("endmonth", &e->event_end->month, 0);
cgiFormInteger("endday", &e->event_end->day, 0);

/* Process begin & end times separately */
cgiFormStringNoNewlines("beginhour", 
                        e->event_begin->hour, 10);
cgiFormStringNoNewlines("endhour", 
                        e->event_end->hour, 10);

event_write(e);

cgiHeaderLocation(cgiScriptName);

