title: How can i get multiple value from an input field using javascript
body: <p>In my code, I have an add function when user click on it. it will capture the user input value from the text and show. any idea how can I do it using javascript</p>
  <p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
  <div class="snippet-code">
  <pre class="snippet-code-js lang-js prettyprint-override"><code>var split = ['S','M', 'L'];
  for (var i = 0; i &lt; split.length; i++) {
    var t = document.getElementById('text-box');
    t.innerHTML += 'Size &lt;input value=' + split[i] + ' type="text"&gt;Description&lt;input type="text" name="vrow" id="price"&gt;'
  }
  function add(){
  //get the description value
  
  }</code></pre>
  <pre class="snippet-code-html lang-html prettyprint-override"><code>&lt;div id="text-box"&gt;
  &lt;/div&gt;
  &lt;button onclick="add()"&gt;ADD&lt;/button&gt;</code></pre>
  </div>
  </div>
  </p>