[jQuery] triggering an event

2006-10-24 Thread Adam van den Hoven
I was wondering having done: $(.foo).click(function (e) {alert (foo);}); Can I force the click event to fire manually, or do I resort to var x = function (e) {alert (foo);} $(#foo).click(x); ele = $(#foo).get(0) x.call( ele, {target:ele}); Adam ___

[jQuery] jQuery Events

2006-10-20 Thread Adam van den Hoven
I was working with the event model and I noticed that while some steps are taken to fix the IE event object some of the cross browser inconsistancies, it doesn't fix all of them. It doesn't even fix the most annoying inconsistancies, namely the target and/or srcElement is not unified. Is there any

Re: [jQuery] Get element ID

2006-10-20 Thread Adam van den Hoven
Keep in mind that this refers to the element on which the event is being handled, NOT the element that originated the event. See http://www.quirksmode.org/js/events_order.html for an explaination of how events are captured and http://www.quirksmode.org/js/events_properties.html for good measure.

[jQuery] Problems with JQuery

2006-10-19 Thread Adam van den Hoven
Hey guys, I'm just starting with jquery and I've hit what seems to be inconsistant behaviour. I have the following markup: form action= span class=control date input id=someID type=text value=HI / input type=hidden value=Huh? class=meta / /span

Re: [jQuery] Problems with JQuery

2006-10-19 Thread Adam van den Hoven
This is all well and good but the document does not make this at all clear. I would not have fallen into this trap if it was documented well. I also would never have expected that calling a find method on anything would ever modify the thing that I was calling it on. It makes sense that sorting