title: How To get values in Span Tag from JS
body: <p>I am trying to make a BMI Calculator using HTML. The inputs come from text fields. I am making some calculation with them in a Javascript function. I want to get the calculated values in a span like this:</p>
  
  <pre><code>&lt;span id="" class=""&gt;Your Calculation Results is = &lt;/span&gt;
  &lt;span id="" class=""&gt;   "" I want the result here ""    &lt;/span&gt;
  </code></pre>
  
  <p>====================================================================
  Edit : The part that i am asking about</p>
  
  <pre><code>&lt;script language="javascript"&gt;
  var bmi = document.getElementById("ID_bmiResult2").innerHTML;
  bmi.value = weight / (heightInMeter * heightInMeter);
  &lt;/script&gt;
  
  &lt;body&gt;
  &lt;span id="ID_bmiResult2"&gt;  &lt;/span&gt;
  &lt;/body&gt;
  </code></pre>
  
  <p>i don't know how to make it ...</p>