title: Pass data from HTML Input text element into a javascript variable
body: <p>I am trying to take a text value, input by the user, pass into a javascript variable and store it so it can be used in math functions after further input. Before that I need to get the inputs stored as variables.
  The input field id is Numb1, Once submit is pressed, I'd think the value input is passed into the firstNumb var in the assignVar function via the document.getElementbyID().</p>
  
  <p>When I input a number, press submit and use the console in chrome to see what firstNumb is I get an uncaught reference error stating firstNumb is not defined.</p>
  
  <p>Where am I going wrong with this?</p>
  
  <p>Here is my form/input and script code</p>
  
  <pre><code>&lt;form&gt;
  &lt;input type="number" id="Numb1"&gt;
  &lt;input name="submit" type="submit" onclick="assignVar()"&gt;
  
  
  &lt;/form&gt;
  
  &lt;script&gt;
  function assignVar() {
  var firstNumb = document.getElementByID("Numb1");
  }
  
  &lt;/script&gt;
  </code></pre>
  
  <p>Thanks for any help</p>