added basic form validation. fixes #3.