title: JavaScript Inputs
body: <p>For my college coursework I have been asked to create a program the works out the cost for painting a room by taking the measurements and multiplying them all together. I've done all of the Pseudo and Flow Charts and stuff. But I'm stuck with this bit. I want the user to input a number into the text field(If there is a way to limit the  to just number please let me know :P) and then once the user presses a button it will write the value below without having to change/refresh the webpage. The code below should work(I think) But anyways, any help is greatly appreciated :)
  Aaron~</p>
  
  <pre><code>&lt;form id="frm1" action="form_action.asp"&gt;
  Number of walls: &lt;input type="number" name="numberOfWallsInput" value="From 4 to 10"&gt;&lt;br&gt;
  Width of walls in meters: &lt;input type="text" name="wallWidthInput" value="From 1 to 25"&gt;&lt;br&gt;
  Height of walls in meters: &lt;input type="text" name="wallHeightInput" value="From 2.4 to 6"&gt;&lt;br&gt;
  &lt;/form&gt;
  
  &lt;p id="demo"&gt;&lt;/p&gt;
  
  &lt;button onclick="myFunction()"&gt;Try it&lt;/button&gt;
  
  &lt;script&gt;
  function myFunction()
  {
  var x = document.getElementById("numberOfWallsInput");
  document.getElementById("demo").innerHTML=x;
  }
  &lt;/script&gt;
  </code></pre>