mvc 5 表单验证电子邮件地址消息 window 错误字段
mvc 5 form validation email address message window over wrong field
我正在使用 MVC 5 表单验证来验证表单上的电子邮件地址字段,但是弹出的消息 window 不在正确的字段上,请参见下文:
这是 3 个字段的代码:
<input class="underlineBox text-box single-line filledIn" data-val="true" data-val-required="The Name field is required." id="Name" name="Name" placeholder="ex. Jon Doe" type="text" value="" data-com.agilebits.onepassword.user-edited="yes">
<input class="underlineBox text-box single-line filledIn" data-val="true" data-val-email="The Email field is not a valid e-mail address." data-val-required="The Email field is required." id="Email" name="Email" placeholder="ex. jdoe@unkown.org" type="email" value="" data-com.agilebits.onepassword.user-edited="yes">
<textarea class="underlineBox text-box multi-line filledIn" data-val="true" data-val-required="The Message field is required." id="Message" name="Message" placeholder="ex. Hi Syd, I would like to start a project together." rows="5"></textarea>
有什么想法吗?
I am using MVC 5 form validation to validate the email address field on a form, but the message window that pops up is not over the correct field
这不是 jQuery Validate 的照片。默认情况下,jQuery 验证只是在字段旁边插入文本。
您显示的弹出窗口是根据您的浏览器进行的 HTML5 验证。这只是意味着您的 JavaScript/jQuery 验证出于某种原因无法正常工作。
我正在使用 MVC 5 表单验证来验证表单上的电子邮件地址字段,但是弹出的消息 window 不在正确的字段上,请参见下文:
这是 3 个字段的代码:
<input class="underlineBox text-box single-line filledIn" data-val="true" data-val-required="The Name field is required." id="Name" name="Name" placeholder="ex. Jon Doe" type="text" value="" data-com.agilebits.onepassword.user-edited="yes">
<input class="underlineBox text-box single-line filledIn" data-val="true" data-val-email="The Email field is not a valid e-mail address." data-val-required="The Email field is required." id="Email" name="Email" placeholder="ex. jdoe@unkown.org" type="email" value="" data-com.agilebits.onepassword.user-edited="yes">
<textarea class="underlineBox text-box multi-line filledIn" data-val="true" data-val-required="The Message field is required." id="Message" name="Message" placeholder="ex. Hi Syd, I would like to start a project together." rows="5"></textarea>
有什么想法吗?
I am using MVC 5 form validation to validate the email address field on a form, but the message window that pops up is not over the correct field
这不是 jQuery Validate 的照片。默认情况下,jQuery 验证只是在字段旁边插入文本。
您显示的弹出窗口是根据您的浏览器进行的 HTML5 验证。这只是意味着您的 JavaScript/jQuery 验证出于某种原因无法正常工作。