title: document.getElementById().value not working
body: <p>I would like to auto calculate a price + commission (12%) and automatically input the result. For example: 100$ + 12% commission = 112$. Problem is here my result is 10012.</p>
  
  <p>Where did I write wrong my code:</p>
  
  <pre><code>&lt;input type="value" class="form-control" id="input"&gt;
  &lt;input type="value" id="output" onkeyup="calc();"/&gt;
  &lt;input id="finalprice" onkeyup="calc();"/&gt;
  &lt;script&gt;
  function calc() {
    var a = document.getElementById("input").value;
    var b = (12/100) ;
    var c = b * 100;
    var e = a + c;
    var f = a + e;
    document.getElementById("output").value = c;
    document.getElementById("finalprice").value = f;
  }
  &lt;/script&gt;
  </code></pre>