Debugged AJAX log in and fixed background issue