[jQuery] Re: Stringing functions within a click event

2009-02-21 Thread Thomas Jaggi
But It would probably be better changing the class instead of the id. On 21 Feb., 15:42, "paul.mac" wrote: > Thanks - would it not be easier to set up a loop that is executed > after all the animations have been finished? As I have 8 numbered form > 0 to 8, will there not be a conflict when yo

[jQuery] Re: Stringing functions within a click event

2009-02-21 Thread Thomas Jaggi
I'm not sure if this is a problem since all the animations are executed at the same time (as far as I know). On 21 Feb., 15:42, "paul.mac" wrote: > Thanks - would it not be easier to set up a loop that is executed > after all the animations have been finished? As I have 8 numbered form > 0 to 8

[jQuery] Re: Stringing functions within a click event

2009-02-21 Thread paul.mac
Thanks - would it not be easier to set up a loop that is executed after all the animations have been finished? As I have 8 numbered form 0 to 8, will there not be a conflict when you end up with 2 objects with id1? Thanks paul On Feb 21, 2:29 pm, Thomas Jaggi wrote: > You could use the callb

[jQuery] Re: Stringing functions within a click event

2009-02-21 Thread Thomas Jaggi
You could use the callback function (http://docs.jquery.com/Effects/ animate#paramsdurationeasingcallback). $("#right").click(function(){ $("#i1").animate({width: '98px', "left": "+=86px"}, 1500, function (){ var id = $(this).attr('id').split('i')[1]; id = id -1; $(thi