Give help. Get help.
I have a problem with my JS code:
I want to achieve that every element with the class .activity is removed. What I do is:
Basically this works fine the first time. But as the one .activity is removed, I append a new one. And the .remove() function does not work there.
I saw that there is a method .live() (.on()), but this takes an event like a click. I have no event; I just want to select every appended element and remove it then.
I do an ajax request loading new data. With this data there come new activities. So i want to remove the old ones and add the new ones.
I hope this is clearer now :)
You must be logged in to reply to this topic.