[jQuery] Re: Why is this example duplicating my content?

2007-10-16 Thread Karl Swedberg
Hi Chris, It's hard to tell without seeing the rest of the markup, but I'm guessing you have more than one element with class=photoframe. If that is the case, you could change this ... var photo = $('.photoframe'); to this ... var photo = $('.photoframe:first'); That way it'll insert a

[jQuery] Re: Why is this example duplicating my content?

2007-10-16 Thread Chris - Implied By Design
It's hard to tell without seeing the rest of the markup, but I'm guessing you have more than one element with class=photoframe. Exactly. The function builds a table around each element with the class 'photoframe'. If that is the case, you could change this ... var photo = $('.photoframe');

[jQuery] Re: Why is this example duplicating my content?

2007-10-16 Thread Jocko
Use the $.each function against a query for the photoframe class: $.each($('.photoframe'), function( index, elem) { // Wrapper methods here, using elem as the reference to each element. ... } That should do it. For more, check out Visual JQuery (http:// visualjquery.com/1.1.2.html),