ajax dynamic controller for log in