Author: Poku | Posted on: 8/12/2009 3:48:06 AM | Views : 365

 Hey
Im having some problems with sending data to my mvc controller with Jquery.Ajax.  With the code below string fName = null, but if i alert candidateName in javascript it have the right value. What am i doing wrong?
$("#tr_" + candidateID).click(function() { var candidateName = $("#candidateName").text().toString(); candidateName = getFirstNameFromFullName(candidateName); $.ajax({ type: "POST", url: "/Admin/GetCandidatesByFirstName/", data: { fName: candidateName }, contentType: "application/json; charset=utf-8", dataType: "json", success: function(response) { $("#Candidates").html(response[0]); }, ...

Go to the complete details ...