javascript - Jquery selector for html select drop down -


currently working jquery selector have query on how find html select drop down using jquery selector input text finding in way possible combine html select drop down .find("input[type='text']" want know how find html select drop down. tried select[name=bar] in code have more 4 html drop down , don't want give this.

any suggestion please me

here jquery code

function bind_change_events(){     $('.cloned_field').on('input',function(e){          if($(this).val().trim().length > 0)         {             //$(this).removeclass("cloned_field");             $(this).addclass("required_field");             var parent_div = $(this).closest("div.cloned-row1,div.cloned-row2,div.cloned-row3,div.cloned-row4,div.cloned-row5").find("input");             parent_div.each(function () {                 $(this).addclass("required_field");             });         }          check_for_validation_removal($(this));         bind_validation();     }); }  function check_for_validation_removal(element){     var parent_div = $(element).closest("div.cloned-row1,div.cloned-row2,div.cloned-row3,div.cloned-row4,div.cloned-row5").find("input[type='text']");     console.log(parent_div);     console.log(parent_div.length);     var invalid_ele = 0;     parent_div.each(function () {          if($(this).val().trim().length == 0){                 invalid_ele = invalid_ele + 1;         }       });     console.log(invalid_ele);     if(parent_div.length == invalid_ele){         parent_div.each(function () {              $(this).removeclass("required_field");              $(this).rules('remove');           });         bind_validation();         update_errors();     }     var parent_div1 = $(element).closest("div.cloned-row1,div.cloned-row2,div.cloned-row3,div.cloned-row4,div.cloned-row5").find("input[type='text']");  } 

thanks in advance


Comments

Popular posts from this blog

java - Date formats difference between yyyy-MM-dd'T'HH:mm:ss and yyyy-MM-dd'T'HH:mm:ssXXX -

c# - Get rid of xmlns attribute when adding node to existing xml -