added persistent form choices and more advanced input validation