setting up functionality for two submits on one page