[jQuery] Re: How to link myFunction(this) to a div

2008-12-16 Thread WebGrunt
Thanks, this seems to do the trick. Test() was only as an example, I use different names in my scripts. Seems like I'll have to read up on the different scpes of "this". Thanks all, and sorry for the noob question. :) On 16 déc, 09:22, brian wrote: > On Mon, Dec 15, 2008 at

[jQuery] Re: How to link myFunction(this) to a div

2008-12-15 Thread WebGrunt
end jQuery to allow method so you > could use $(this).test();http://docs.jquery.com/Core/jQuery.fn.extend > > Rik > > 2008/12/15 WebGrunt : > > > > > > > Hi > > > I'm new to jQuery and here's one thing that doesn't make sense.  How >

[jQuery] How to link myFunction(this) to a div

2008-12-15 Thread WebGrunt
Hi I'm new to jQuery and here's one thing that doesn't make sense. How do I link an existing function with "this" as argument to a div? The function to be called is really simple: function test(e) { alert(e.id); //Also tried e.getAttribute("id") or e.attr("id") } Here is what I tried so f