jQuery Form Plugin 的clearForm怎么用?

wvtjplh 2009-12-04 11:14:19

<script type="text/javascript">
$(document).ready(function() {
var options = {
target: '#output2', // target element(s) to be updated with server response
success: showResponse // post-submit callback
};
$('#myForm2').submit(function() {
$(this).ajaxSubmit(options);
return false;
});
});
function showResponse(responseText, statusText) {
alert('状态: ' + statusText + '\n返回结果: \n' + responseText);
clearForm();
}

</script>


如何用clearForm方法把表单内容清除掉?
谢谢!
...全文
117 1 打赏 收藏 转发到动态 举报
写回复
用AI写文章
1 条回复
切换为时间正序
请发表友善的回复…
发表回复
sean1203 2009-12-15
  • 打赏
  • 举报
回复
jf

52,797

社区成员

发帖
与我相关
我的任务
社区描述
Web 开发 Ajax
社区管理员
  • Ajax
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧