小编Jun*_*que的帖子

检查表单是否成功提交html5

我有以下代码.

<div class="form-group">
    <label for="store_account_name">Store Title</label>
    <input type="text" value="" class="form-control" name="store_account_name" id="store_account_name" placeholder="Please insert store title of the external store" required />
</div>
<div class="form-group">
    <label for="store_url">Store URL</label>
    <input type="url" value="" class="form-control" name="store_url" id="store_url" placeholder="Please insert store URL as described in help section" required />
</div>
Run Code Online (Sandbox Code Playgroud)

在提交按钮上,我想检查表单是否已经过验证.我有一个listner事件,它有preventDefault按钮.所以我只想在成功验证这两个输入时发送ajax调用.是否有任何JS函数来检查验证的状态或任何css属性是否添加到无效字段.

javascript forms ajax jquery html5

2
推荐指数
1
解决办法
2万
查看次数

标签 统计

ajax ×1

forms ×1

html5 ×1

javascript ×1

jquery ×1