1. Extension via $.extends ($.fn.validatebox.defaults.rules,)
$.extend ( $.fn.validatebox.defaults.rules, { idcard: {// Verify ID function (value) { return /^\d{15} (\d{2}[a-za-z0-9])? $/I.test (value); }, ' ID number format incorrect ' }, })
Calling methods
<class= "Easyui-validatebox" validtype= "Idcard">
Property:
name |
type |
Description |
Default Value |
Required (required) |
Boolean (Boolean) |
Define form fields that must be filled in. |
False |
Validtype (authentication type) |
String (String) |
Define the type of validation for the form field, such as email, URL, etc. |
Null |
Missingmessage (not filled in prompt) |
String (String) |
The prompt message that appears when form fields are not filled in. |
This field is required. |
Invalidmessage (Invalid hint) |
String (String) |
The prompt that appears when the contents of the form field are validated as invalid. |
Null
|
Extended Validation of jquery Easyui