View Single Post
Old 12-31-2012, 12:26 AM   PM User | #4
AndrewGSW
Senior Coder

 
Join Date: Apr 2011
Location: London, England
Posts: 2,120
Thanks: 15
Thanked 354 Times in 353 Posts
AndrewGSW will become famous soon enough
Code:
$('#divA').toggle(function () {
  $('#divB').stop().fadeOut(500);
}, function () {
  $('#divB').stop().fadeIn(500);
});
The jQuery docs for toggle seem to be wrong.. that is, the wrong way round

Quote:
handler(eventObject)A function to execute every even time the element is clicked.
handler(eventObject)A function to execute every odd time the element is clicked.
__________________
"I'm here to save your life. But if I'm going to do that, I'll need total uninanonynymity." Me Myself & Irene.
Validate your HTML and CSS

Last edited by AndrewGSW; 12-31-2012 at 12:29 AM..
AndrewGSW is offline   Reply With Quote