index submitting post data with directLogin and redirecting to main.html. Missing form fields checking and pass hashing