title: Using getElementsByTagName then using getElementById
body: <p>I'm trying to get the value from an input with an ID inside a LI element.</p>
  
  <p>But when I call the <code>getElementsByTagName()[0].getElementsById()</code> I get the error <code>numLi[i].getElementById is not a function</code> being numLi an array with LI elements. Here's my whole js code</p>
  
  <pre><code>$('form').submit(function()
  {
      var headOne = document.getElementById('inputHead').value;
      var archive = document.getElementById('inputPara').value;
      var numLi = document.getElementById('uList').getElementsByTagName('li');
      var tagsToPost = '';
      for(i = 0;i&lt;numLi.length;i++)
      {
          var ff = numLi[i].getElementById('tagOne');
  
         if(i&lt;=numLi-1)
         {
              tagsToPost = tagsToPost + ff.value + ',';
         }
         else
         {
          tagsToPost = tagsToPost + ff.value;
         }
      }
  
  });
  </code></pre>
  
  <p>And the html part I'm trying to access</p>
  
  <pre><code> &lt;form action="javascript:void(0);"&gt;
  &lt;div class="col-md-3"&gt;
  
      &lt;div id="enlacesList"&gt;
          &lt;ul id="uList"&gt;
  
                  &lt;li class='listaLink'&gt;&lt;input type="text" id="tagOne" class="tags" placeholder="Tags" autocomplete="off"&gt;&lt;/li&gt;   
                  &lt;li class='listaLink'&gt;&lt;input type="text" id="tagOne" class="tags" placeholder="Tags" autocomplete="off"&gt;&lt;/li&gt;      
  
          &lt;/ul&gt;
      &lt;/div&gt;
       &lt;button id="addgregador" type="button" autocomplete="off"&gt;&lt;span class="glyphicon glyphicon-plus"&gt;&lt;/span&gt;&lt;/button&gt;&lt;button id="desadd" type="button" autocomplete="off"&gt;&lt;span class="glyphicon glyphicon-minus"&gt;&lt;/span&gt;&lt;/button&gt;
  &lt;/div&gt;
  &lt;div class="col-md-9" id="containerTexto"&gt;
      &lt;div id="textoPregunta"&gt;
          &lt;div id="textHeading"&gt;&lt;input type="text" name="headingOne" id="inputHead" placeholder="Titulo de la pregunta" autocomplete="off"&gt;&lt;/div&gt;
          &lt;div id="textContent"&gt;&lt;textarea id="inputPara" rows="33" cols="84" placeholder="Respuesta, explicación..." autocomplete="off"&gt;&lt;/textarea&gt;&lt;/div&gt;
          &lt;input type="submit" id="editOk" value="Enviar" class="btn btn-primary" autocomplete="off"&gt;&lt;input type="reset" id="editNot" value="Cancelar" class="btn btn-danger" autocomplete="off"&gt;
      &lt;/div&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p></p>
  
  <p>The program breaks in the line <code>var ff = numLi[i].getElementById('tagOne');</code>.</p>