added fn for getting form data