bootstrapValidator添加到验证规则到HTML上

喜欢ヅ旅行 2022-06-15 02:26 212阅读 0赞

添加到验证规则到HTML上

  1. <div class="form-group">
  2. <label class="col-lg-3 control-label">Username</label>
  3. <div class="col-lg-5">
  4. <input type="text" class="form-control" name="username"
  5. data-bv-message="The username is not valid"
  6. required
  7. data-bv-notempty-message="The username is required and cannot be empty"
  8. pattern="[a-zA-Z0-9]+"
  9. data-bv-regexp-message="The username can only consist of alphabetical, number" />
  10. </div>
  11. </div>

发表评论

表情:
评论列表 (有 0 条评论,212人围观)

还没有评论,来说两句吧...

相关阅读