title: How to display only one of the show/hide buttons using jquery?
body: <p>I am stuck here.  Here is what I am trying to do..If the image and description list are visible, only the hide button should be displayed. If the image and description list are hidden, only the show button should be visible.  Here is what I tried to do:</p>
  
  <pre><code>$("#hide").toggle('slow');
  $("#show").toggle('slow');
  </code></pre>
  
  <p>Here is my js code:  $(document).ready(function(){ $("#hide").click(function(){ $("img, dl").hide(); }); $("#show").click(function(){ $("img, dl").show(); $(document).ready(function(){ $('#show').hide(); function clickHandler() { $('#hide').toggle('slow'); $('#show').toggle('slow'); } }); }); }); When the page loads only the hide button should show. If the image and description lists are not visible, the show button should be displayed. Both buttons are displayed when the page loads
  What is wrong with this?</p>