Thanks for the reply, for now I’ll just use hide() instead of remove() till I’ll find some time to do some isolated test.

Kush

 

-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Blair McKenzie
Sent: Thursday, 2 November 2006 3:49 PM
To: jQuery Discussion.
Subject: Re: [jQuery] Reset JQuery collection

 

If you have stored $('.boxes') in a variable before the removal and checked size after the removal, you would get this problem. But you shouldn't if you just use $('.boxes') again.

Blair

On 11/2/06, Khurshid MUROD <[EMAIL PROTECTED]> wrote:

Hi,

Is there any way to reset JQuery collection.

For example I do this: $('.boxes').size(), returned 3
Then I do this: $('.boxes:visible').remove(); Let's assume there were 2
visible boxes.
So logically I'd expect JQuery to return 1 when I do this again:
'.boxes').size(), but it is still returning 3.

Is there a way to reset JQuery internal collection or somesort.

Thanks



_______________________________________________
jQuery mailing list
[email protected]
http://jquery.com/discuss/

 

_______________________________________________
jQuery mailing list
[email protected]
http://jquery.com/discuss/

Reply via email to