// 不須要的name加到下面
var
excludes = [
'name1'
,
'name2'
,
'name3'
];
$.each(excludes,
function
(i, v) {
excludes[i] =
'[name="'
+ v +
'"]'
;
});
excludes = excludes.join(
','
);
var
param = $($(
'#myform'
).prop(
'elements'
)).not(excludes).serialize();