$('foo').stopObserving();
will stop observing all observers on id="foo"
$('foo').stopObserving('click');
will stop click observers on id="foo"
$('foo').stopObserving('change');
will stop change observers on id="foo"
........ i think you get the idea!HTH Alex Mcauley http://www.thevacancymarket.com ----- Original Message ----- From: "Paul Lynch" <[email protected]> To: "Prototype & script.aculo.us" <[email protected]> Sent: Tuesday, August 18, 2009 6:27 PM Subject: [Proto-Scripty] Which parameters to stopObserving are optional? > > I noticed in the code for stopObserving that it appears you can get > away with just specifying the element, and then (perhaps) it cancels > all observers for all events for that element. However, the > documentation surprisingly does not mention this ability, but lists > the element, event name, and event handler function as though they > were required elements. > > It would be very convenient to be able to say Event.stopObserving > (someElement), and so I'm wondering whether the documentation is > simply incomplete, or whether it was intentionally trying to > discourage people from using the method that way. > > Thanks, > --Paul > > > --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Prototype & script.aculo.us" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/prototype-scriptaculous?hl=en -~----------~----~----~----~------~----~------~--~---
