I have tried to get values from my HTML element, which type is input. I have applied the below code. It works fine for input elements, but for select drop-down values not listed in the code. How can I get value from element type input, select, etc in jQuery?
var InputElement=$('#MyDiv').find('input'); if(InputElement.length > 0) { $(InputElement).each(function(){ var val = $(this).val(); console.log(val); }); }
Question and answer is powered by AnsPress.io