title: Calculate area from inputs in Javascript
body: <p>I've got a very simple javascript calculator here but it doesn't seem to be working. I'm sure it's something very simple to solve but just can't see it. I've spent a while on it and thought I'd be better off asking here. Any suggestions? Thanks! <a href="http://jsfiddle.net/z98gb/7/" rel="nofollow">http://jsfiddle.net/z98gb/7/</a></p>
  
  <pre><code>Width &lt;input type="Text" name="width" size="4"&gt;  
  Height &lt;input type="Text" name="height" size="4" onkeyup=""&gt; &lt;br&gt;&lt;br&gt;
  Area &lt;input type="Text" name="area" id="area" size="4"&gt; &lt;br&gt;&lt;br&gt;
  &lt;input type="button" name="calculate" id="area" size="4" onclick="calculateArea()"    value="calculate"&gt;
  </code></pre>
  
  <p>And here's the javascript:</p>
  
  <pre><code>function calculateArea() {
  var width = document.getElementById("width").value;
  var height = document.getElementById("height").value;
  var area = width * height;
  document.getElementById("area").value = area;
  </code></pre>
  
  <p>}</p>