I’m trying to use jsFiddle to simulate an ajax response but I’m getting an undefined value. Does anyone know how to do this? My fiddle is here:
http://jsfiddle.net/heaversm/v75vN/10/
and to see the problem click on “login” from the result box
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
You are returning from
$.ajax‘s callbacks (successanderror). Since the$.ajaxmethod give you callback hooks, you should provide the same in theloginUserfunctionAnd then use that callback to know when the operation has completed: