I am trying to pass in mutliple data into AJAX .post(). This is what I’ve done so far:
$('form#tutorTableForm').live('submit', function()
{
var cid = $('#courseSelect').val();
var lid = $('#lessonSelect').val();
var lessonCount = $('#lessonSelect option:selected').attr('id');
$.post('', $(this).serialize(), function(response){
alert(response);
});
return false;
});
I want to also pass in cid and lid. How would I do that?
I’m using live instead of on because our app is using the old version.
I guess you could create an object that contains all the data, like this: