Hello, Thanks for the prompt reply. Yes I have used the newclass and tried. But the problem remains same. I think I have figured out the effecting place. I have used the jeditable plugin for the editable as follows.
$('.plus'+num).live("mouseover", function(){ $('.plus'+num).editable(' http://localhost/editinplace0/save.php?p=add'+num,{ submit : '<img src="images/ok.png">', indicator : '<img src="images/loading.gif">', tooltip : 'Click to edit...', style : 'display: inline', width : '100px', onblur : 'submit' }); }); Here* '.plus'+num* is the new class where *num* is a variable to make every class different. And i have passed 'p=add'+num by get method for the reference address to store the changed data. eg. if .plus1 is edited then it goes and saves in add1, if plus2 then num2 and so on. Now the problem is that once i have moved the mouse over all the dynamically added elements and delete one element, even though the class has changed automatically, the value i had passed by $_GET method doesnot change. suppose i have deleted plus2 after i have moved mouse over all the existing elements, *old class old reference new class new reference* plus1 add1 plus1 add1 plus2 add2 plus2 *add3* plus3 add3 plus3 * add3* plus4 add4 Now here the class has changed from plus4 to plus3 but the reference the i have send through $_GET method doesnot update. What is causing this this problem? Hoping for the prompt reply. Sanam. On Sun, Jul 5, 2009 at 10:47 PM, Josh Powell <seas...@gmail.com> wrote: > > Also, be very, very careful with using mouseover, mouseout, or > mousemove with live events. The way live events work is to put an > event handler on the document and catch events as they bubble up and > check them against the selector. So, when using mouseover live > events, you are executing a comparison against the selector every time > the mouse moves over an element on the page. This can cause some > dramatic slowdowns, especially if you are using multiple live events > of these types. It's often better to use regular events for > mouseover, mouseout, and mousemove. > > Josh Powell > > On Jul 5, 9:21 am, Nic Hubbard <nnhubb...@gmail.com> wrote: > > Pretty sure that you have to create a new .live() event for your > > expected class. So, you would need to do: > > > > $(".newClass").live("mouseover", function(){ > > //clickable function here...... > > ------------------------ > > }); > > > > On Jul 5, 12:30 am, Sanam <kcssm2...@gmail.com> wrote: > > > > > Hello, > > > I got this problem with live() event.I have used it as follows. > > > > > $(".addressDiv span").live("mouseover", function(){ > > > //clickable function here...... > > > ------------------------ > > > }); > > > > > I have used the live() event to trigger the function on mouseover in > > > the dynamically added elements. But the problem i got is that once the > > > live event is called it takes the class of the element and stores. And > > > when the class of that particular element is changed dynamically the > > > live() event does not detect the new classed added dynamically, > > > instead it takes the former class. Live() event does not update the > > > class. How can I solve this problem? > > > > > Sanam >