make modal close on submit. Also recognize email field