JQuery .animate - Want to use it as a toggle like slideToggle but without hiding the element


ok have got .animate function working.

 

 

$(function() { $('div#sys-req-heading').click(function() {     $('div#sys-req').slidetoggle("slow");           $('div#sys-req-heading').animate({                     bottom: "158px"           }, "slow" );   }); });  

 

 

 

#sys-req-heading { width: 150px;           height: 15px;           line-height:15px;           position: fixed;           left: 50%;           margin-left: -76px;           bottom: 46px; }  

 

so works fine animating on first click want animate bottom:46px; in css after click again. kind of toggle feature. thinking might need if statements see current bottom: value not sure how or if possible.

 

any ideas?

 

 

thanks

jquery toggle menu. 

http://jsfiddle.net/nancyo/ap9hm/

 

 

 

nancy o.



More discussions in Dreamweaver support forum


adobe

Comments

Popular posts from this blog

How to set the order of FAQs instead of alphabetical

Thread: Get UK Keyboard working

how do I change the e-mail address for my merchant account