[Prototype-core] Triggering event / calling an element's event handlers

2008-04-02 Thread sam
Hi all, After digging through to Prototype docs I couldn't find the answer to the following question: How do you call an element's handlers for a specific event? For instance, I want to call all 'click' handlers I attached to a link. Calling its onclick() method is not it. Example code: Assume

[Prototype-core] Re: Triggering event / calling an element's event handlers

2008-04-02 Thread sam
Sorry, copy-paste-of-death, the correct example code would be: Assume I have a link 'foo': Event.observe('foo', 'click', doSomething); Event.observe('foo', 'click', doSomethingElse); And I have a link 'bar': Event.observe('bar', 'click', function(e) { // *** Just how can I call all of

[Prototype-core] Re: Triggering event / calling an element's event handlers

2008-04-02 Thread sam
So sorry again, I just realised this is the wrong list for support questions.Will repost in the user mailing list. On 2 Apr., 15:03, sam <[EMAIL PROTECTED]> wrote: > Sorry, copy-paste-of-death, the correct example code would be: > > Assume I have a link 'foo': > > Event.observe('foo', 'click