Converted login form to AJAX (phew)