JQuery Validation Library (Document! X Sample)
jQuery.validator Namespace / options type / focusCleanup Option
In This Topic
    focusCleanup Option
    In This Topic
    If enabled, removes the errorClass from the invalid elements and hides all errors messages whenever the element is focused. Avoid combination with focusInvalid.
    Syntax
    var options; // Type:  jQuery.validator.options
    var instance; // Type:  jQuery.validator
    instance = $(".selector").validate(options);
    
    var value; // Type:  boolean
    
    // Get value
    value = instance.focusCleanup;
    // Set value
    instance.focusCleanup = value;
    var focusCleanup : boolean;
    Browser Compatibility
    8
    5
    5
    See Also