title: Copy only numeric value from div
body: <p>I am trying to make on button click only numeric value should be copied in textbox not character. Any can help me?</p>
  
  <p>HTML</p>
  
  <pre><code>&lt;div class="more"&gt;
      &lt;div id="dvDistance"&gt;
          10 kms
      &lt;/div&gt;
      &lt;input type="number" id="firstNumber" /&gt;
      &lt;script&gt;
          function copyText() {
              var output = document.getElementById("dvDistance").innerHTML;
              document.getElementById("firstNumber").value = output;
          }
      &lt;/script&gt;
      &lt;input type="button" onClick="copyText();" Value="Multiply" /&gt;
      &lt;/p&gt;
  &lt;/div&gt;
  </code></pre>