title: Can't execute function in javascript
body: <p>I've looked a lot in this website for an answer and honestly I've seen many close answers to my problem but still can't make it work.</p>
  
  <p>I want to use a input textbox value and put it in javascript function then use javascript to calculate what I've given to the textbox for me and then put the answer to another paragraph in my html document (in this case I want to use <code>kmh=ms*3.6</code> with return to do the calculation)<br>
  So this is my function code:</p>
  
  <pre><code>function msToKM() {document.getElementById('mstokm').innerHTML='&lt;input type="text" name="mstokm" id="mstokmh" value="10"/&gt;m/s&lt;br&gt;&lt;br&gt;&lt;button type="button" class="buttons" onclick="convMSKM()" style="padding: 10px 10px;"&gt;Equals to!&lt;/button&gt;';} 
  function convMSKM () {mstokm= document.getElementById('mstokmh'); mstokmA(mstokm);}
  function mstokmA(ms) {return kmh= ms*3.6; document.getElementById('AmstokmA').innerHTML=kmh;}
  </code></pre>
  
  <p>And I'm specificly having a problem with this part of the code:</p>
  
  <pre><code>function mstokmA(ms) {return kmh= ms*3.6; document.getElementById('AmstokmA').innerHTML=kmh;}
  </code></pre>
  
  <p>because it's not executing the last part of it.<br>
  I can provide the html codes as well if needed.</p>
  
  <p>How can I fix this?</p>