title: Slide toggle with delay
body: <p>I have a navigation with a slide up effect on the links, which once clicked, the page slides up from the bottom, while the main page called #portfolio slides down, once opened, if the user clicks the same link again I want the page to slide down.</p>
  
  <p>what i'm trying to accomplish is that if once one of the 2 panels, #aboutpage and #contactpage is open while I click on the other one, for example if #aboutpage is open, and I click on the link for #contactpage, I want the about page to slide down, once down the #contactpage slides up. I have tried a dozen times with a dozen different methods and I can't seem to get it to work.</p>
  
  <p><a href="http://maximsiebert.com/unamed/Untitled-1.html" rel="nofollow">http://maximsiebert.com/unamed/Untitled-1.html</a></p>
  
  <pre><code>    $('.about').click(function() {
      if (!$('#aboutpage').is(":visible")) {
      $('#aboutpage') .slideToggle(1000)
      $('#portfolio') .slideToggle(1000)
      }
  else if ($(('#contactpage').css('display') == "block")) {
      $('#contactpage') .slideToggle(1000)
      $('#aboutpage') .delay(1000).slidetoggle(1000)
  }else {
      $('#portfolio').slideDown(1000);
       $('#aboutpage').slideUp(1000);
  }
  });
  </code></pre>