This post shows you that how to get the value of multiple hidden field by name property. Let’s see an example. <input type=”hidden” name=”hidden_data[]” value=”3180″> <input type=”hidden” name=”hidden_data[]” value=”3181″> <input type=”hidden” name=”hidden_data[]” value=”3182″> <input type=”hidden” name=”hidden_data[]” value=”3183″> Just execute the below script. $(‘input[name=”hidden_data[]”]’).each(function(k,v){ alert(v.value); }); Please follow and like us:
Tag: Javascript
How to get the checked value of multiple checkbox by name using Jquery ?
This post shows you that how to get the checked value of multiple checkbox by name property. Let’s see an example. <input type=”checkbox” name=”checkbox_name[]” value=”Checkbox_1″> <input type=”checkbox” name=”checkbox_name[]” value=”Checkbox_2″> <input type=”checkbox” name=”checkbox_name[]” value=”Checkbox_3″> <input type=”checkbox” name=”checkbox_name[]” value=”Checkbox_4″> Just execute the below script. $(‘input[name=”checkbox_name[]”]:checked’).each(function(k,v){ alert(v.value); }); If you want to get the value of multiple checkbox
How to get the nth child without any selector in Jquery ?
This post shows you that how to get the any child without any selector like id,class or else. Let’s see some examples. Example 1: Using ul & li <ul> <li>Cofee </li> <li>Tea </li> <li>Beer </li> <li>Water </li> </ul> Case 1 : If you want to get the 2nd child text of ul $(‘ul > :nth-child(2)’).text();