[jQuery] Re: Attaching events to dynamically added fields

2009-01-06 Thread canadaduane
Use the "livequery" plugin. It's absolutely beautiful. On Jan 5, 3:26 pm, Rob wrote: > Thanks Brian, > > At the moment I'm using basically the simplest implementation of the > plugin.  I'm using inline rules, so I don't have to worry about the > brackets yet.  I do understand the event delegati

[jQuery] Re: how i can access classes in my div?

2008-05-13 Thread canadaduane
I wonder if you're looking for 'filter' instead of 'next'? $('.bloc-top').click(function(){ $(this).filter('.bloc-center').slideToggle('slow'); }); > looking at your code, the action is something like this: > "when the user clicks on a bloc-top element, slide-toggle the next > bloc-center ele

[jQuery] Re: New to JQ

2008-05-08 Thread canadaduane
y, "" tags, then you should also change that line to: >> $("h1 a").click(function(){ You can also change it to "header" (in the jQuery code, not the html) if you want it to work on all H1, H2, H3, ... etc. tags. Duane Johnson (canadaduane)