JQuery Validation Library (Document! X Sample)
jQuery.validator Namespace / options type / rules Option
In This Topic
    rules Option
    In This Topic
    Key/value pairs defining custom rules. Key is the name of an element (or a group of checkboxes/radio buttons), value is an object consisting of rule/parameter pairs or a plain String. Can be combined with class/attribute/data rules. Each rule can be specified as having a depends-property to apply the rule only in certain conditions. See the second example below for details.
    var options; // Type:  jQuery.validator.options
    var instance; // Type:  jQuery.validator
    instance = $(".selector").validate(options);
    var value; // Type:  any
    // Get value
    value = instance.rules;
    // Set value
    instance.rules = value;
    var rules : any;
    Browser Compatibility
    See Also