jQuery Validate Element
        Posted  
        
            by Idsa
        on Stack Overflow
        
        See other posts from Stack Overflow
        
            or by Idsa
        
        
        
        Published on 2010-05-25T20:59:31Z
        Indexed on 
            2010/05/25
            21:01 UTC
        
        
        Read the original article
        Hit count: 334
        
jQuery
|jquery-validate
jQuery Validate plugin passes element value to inline validate functions. I'm trying to get element's id and an error telling that "element.attr is not a function" :
function someFunction(element) {
  var elementId = element.attr('id');
}
rules: {
  someFiled: {
    required: someFunction
  }
}
© Stack Overflow or respective owner