方法一:用text代替hidden,设置text隐藏

<input id="id" name="id" style="display: none;" value="0" />



方法二:单独处理hidden类型

jQuery("#saveForm").form("reset");
jQuery("input[type='hidden']").val("");



方法三:使用clear代替reset

jQuery("#saveForm").form("clear");


注意: clear之后表单的radio也被情况,html的checked也不能生效了,要js重新给radio设置选中值;



关注下面二维码,订阅更多精彩内容。

表单reset无法重置hidden的解决方案_js