added client side validation for email and presence