下面使用jquery自带方法serializeArray
$.ajax({
type: "POST",
url: "/Mall/ajax_cart.html",
data: $(form).serializeArray(),
dataType: 'json',
success: function(msg){
$("#allmoney").html("¥"+msg);
}
});