Send multiple <select> elements with jQuery POST

后端 未结 2 1773
北海茫月
北海茫月 2021-01-06 23:34

I have this jQuery code to add');

and then just serialize the form before you send it in:

var my_data = $("form").serialize();
...

Edit: The complete example:

$("#add").click(function() {
    $('#selected > tbody:last').append('');
    });
                                                                      ^^^^^^^^^^^^^^^^^^^

and:

$('#course_update').click(function() {

var my_data = $("form").serialize();

$('#update_status').html('');
$.post('../update.php', my_data, function(data) {
    $('#update_status').html(data);
    return false;
 });
});

提交回复
热议问题