title: Javascript Show/hide
body: <p>I dont know whats the mistake:</p>
  
  <pre><code>&lt;script&gt;
                  function craft()
      {
      document.getElementById(craft).style.visibility="visible";
      document.getElementById(smell).style.visibility="hidden";
      document.getElementById(other).style.visibility="hidden";
      }
  
  function smell()
  {
  document.getElementById(craft).style.visibility="hidden";
  document.getElementById(smell).style.visibility="visible";
  document.getElementById(other).style.visibility="hidden";
  }
  
  function other()
  {
  document.getElementById(craft).style.visibility="hidden";
  document.getElementById(smell).style.visibility="hidden";
  document.getElementById(other).style.visibility="visible";
  }
          &lt;/script&gt;
  
  
  
      &lt;a onclick ="craft()" href="#"&gt;Craft&lt;/a&gt;&lt;br&gt;
      &lt;a onclick ="smell()" href="#"&gt;Smell&lt;/a&gt;&lt;br&gt;
      &lt;a onclick ="other()" href="#"&gt;Other&lt;/a&gt;&lt;br&gt;
      &lt;div id="craft" style="display: none;" &gt;CraftCraftCraftCraftCraftCraftCraft&lt;/div&gt;&lt;br&gt;
        &lt;div id="smell" style="display: none;" &gt;SmellSmellSmellSmellSmellSmellSmell&lt;/div&gt;&lt;br&gt;
          &lt;div id="other" style="display: none;" &gt;OtherOtherOtherOtherOtherOtherOther&lt;/div&gt;&lt;br&gt;
  </code></pre>
  
  <p>Im trying to make somethink like a menu. When i click Craft button, there will apear just the contain</p>
  
  <p>I cant find the mistake...
  I tryed the code in browser, but there apeared jut the links... Ans when i clicked them, nothing happend...</p>