title: how to add a h1 inside a div using javascript
body: <p>I'm writing a HTML where I want to populate a <code>h1</code> using <code>Javascript</code>. Here I'm able to populate text, but not the <code>h1</code>. Below is my code.</p>
  <pre><code>function getTheIncident(keyWord, text) {
      showTheDiv();
      console.log(keyWord + &quot;\t&quot; + text);
  
      var e = document.getElementById('textResult');
      e.innerHTML = text.replace('\^', '\'');
  }
  </code></pre>
  <p>and this gives me the output as shown in the picture below.</p>
  <p><a href="https://i.stack.imgur.com/4nQ7g.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/4nQ7g.png" alt="enter image description here" /></a></p>
  <p>MY aim is to add a <code>h1</code> with content as <code>Description</code>. Basically like</p>
  <pre><code>&lt;h1&gt;Description&lt;/h1&gt;
  </code></pre>
  <p>just above <code>A procurement order has been placed for a RAM with 128 Gig</code></p>
  <p>please let me know on how can I do this.</p>