Removed all uses of var in login and register
Need to check if the submit button is found in , not the form itself. Fixed login and register, should work now.