1
<input data-parsley-trigger="focusout"
data-parsley-remote="/MailValidation"
data-parsley-remote-message="error"
placeholder="[email protected]"
type="email"
name="Mail"
id="Mail"
required
value="@Model.Mail"
class="form-control" />
JS
var p = $("form").parsley();
$('#SaveButton').click(function() {
p.validate();
if (p.isValid()) {
this.form.submit();
}
});
香菜无效。
p.isValid()
返回null
我无法使其工作。另外,我在互联网上找不到任何whenValidate
的例子。我发现的资源非常不足。你能帮我解决这个问题吗?