Advertisement
Virajsinh

Get multiple element value in Array Using jQuery

Feb 26th, 2022
1,477
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. // https://stackoverflow.com/questions/44961664/get-multiple-element-value-in-jquery
  2.  
  3. var values = $('input').map(function() {
  4.     return $(this).attr('value');
  5. }).toArray();
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement