title: Store into an array selected options from differents selects with javascript
body: <p>I have a n number of selects like those:</p>
  
  <pre><code>&lt;select id="select1"&gt;
          &lt;option value="1"&gt;test1&lt;/option&gt;
          &lt;option value="2" selected="selected"&gt;test2&lt;/option&gt;
          &lt;option value="3"&gt;test3&lt;/option&gt;
      &lt;/select&gt;
  
      &lt;select id="select2"&gt;
          &lt;option value="1"&gt;asdf&lt;/option&gt;
          &lt;option value="2" selected="selected"&gt;fdsa&lt;/option&gt;
          &lt;option value="3"&gt;asdf&lt;/option&gt;
      &lt;/select&gt;
  </code></pre>
  
  <p>And I want to select an option in each one, after that click a button and those options are stored into an array so I can format it like a JSON later. I have the following code working for one option:</p>
  
  <pre><code>&lt;button onClick="GetSelectedItem('select1');"&gt;Get Selected Item&lt;/button&gt;
  
  
  var arr1 = [];
      function GetSelectedItem(el)
      {
          var e = document.getElementById(el);
          var strSel =e.options[e.selectedIndex].text;
  
          arr1.push(strSel);
          console.log(arr1);
  
      }
  </code></pre>
  
  <p>but I have no idea how to do this for more than 1 select.</p>