I store a jQuery object ($remove=$(’img.remove’);) in global space at
document(ready). Later in the script, I use an AJAX get call which
removes one of the images with that class and reloads the div
container. The reload has a callback function which needs the number
of elements with the 'remove' class ($(’img.remove’).length).

In the callback function, should I code $remove.length or $
('img.remove').length? Is $remove and $('img.remove') equivalent since
the DOM changed since I stored the original jQuery object?

Thanks in advance.
John
NYC, USA

Reply via email to