How do I remove div's from displaying
<p>Here's the menu:</p>

<pre><code>&lt;a id="page1" href="" onclick="loadPage('page1')"&gt;Home&lt;/a&gt;
    &lt;a id="page2" href="" onclick="loadPage('page2')"&gt;About us&lt;/a&gt;
    &lt;a id="page3" href="" onclick="loadPage('page3')"&gt;Services&lt;/a&gt;
    &lt;a id="page4" href="" onclick="loadPage('page4')"&gt;Partners&lt;/a&gt;
    &lt;a id="page5" href="" onclick="loadPage('page5')"&gt;Contact us&lt;/a&gt;
</code></pre>

<p>The javascript so far:</p>

<pre><code>&lt;script&gt;
    var var1="";
    function loadPage(varcontent){
      var1=varcontent;
      alert(var1);
    }

    &lt;/script&gt;
</code></pre>

<p>Here's the div:</p>

<pre><code>&lt;div id="page_1" class=welcome_bye_holder&gt;
      &lt;h1 id="page_1"&gt;Welcome to Cyber Technician:&lt;/h1&gt;
      &lt;p1 id="page_1"&gt;An I.T. Technician and cyber security&lt;br&gt; for the         &lt;br&gt;Southport, North Sefton area.&lt;/p1&gt;
    &lt;/div&gt;
</code></pre>

<p>So what i basically need is some javascript that removes divs aswell as the content within them unless page1 == document.GetElemenyById="page_1". The best I could find is var elem = document.getElementById("myDiv");
elem.parentNode.removeChild(elem); from what I understand from that is it only removes the content and not the divs, unless I am mistaken.</p>