简体   繁体   English

使用ParselyJS验证表单

[英]Validate a form using ParselyJS

I was wondering how to validate a simple form in parsely, this is my basic form email, username, firstname, lastname and password. 我想知道如何验证一个简单的表单,这是我的基本表单电子邮件,用户名,名字,姓氏和密码。 I have just downloaded parsely and have looked at a few examples but still dont understand 我刚刚解析下载并查看了一些示例,但仍然不明白

<input id='remail' type='text' class='textinput' style="border-radius:5px; color: rgb(170, 170, 170); margin-left: 10px; margin-top: 10px; width: 266px; height: 16px; padding: 6px;" />
<input id='rusername' type='text' class='textinput' style="border-radius:5px; color: rgb(170, 170, 170); margin-left: 10px; margin-top: 10px; width: 266px; height: 16px; padding: 6px;" />
<input id='rfirstname' type='text' class='textinput' style="border-radius:5px; color: rgb(170, 170, 170); margin-left: 10px; margin-top: 10px; width: 266px; height: 16px; padding: 6px;" />
<input id='rlastname' type='text' class='textinput' style="border-radius:5px; color: rgb(170, 170, 170); margin-left: 10px; margin-top: 10px; width: 266px; height: 16px; padding: 6px;" />
<input id='rpassword' type='password' class='textinput' style="border-radius:5px; color: rgb(170, 170, 170); margin-left: 10px; margin-top: 10px; width: 266px; height: 16px; padding: 6px;" />
<input id='rcpassword' type='password' class='textinput' style="border-radius:5px; color: rgb(170, 170, 170); margin-left: 10px; margin-top: 10px; width: 175px; height: 16px; padding: 6px;" />

There is a good article available here: 这里有一篇很好的文章:

Easily Validating Forms With Parsley JS 使用Parsley JS轻松验证表单

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM