edited form elements
email field added
more syling
more mark up
rever to IF-ELSE due to bug using the loop version; loop version is bug-free when run as a standalone script