Hi, I have implemented a Drag and Drop effect with jQuery. To make it easier, I read a list of elements from the database, these elements can be moved into a different folder. The Folders show the amount of Elements.
Here you see my Folders: "<li id=\"{$value['Cookbook']['id']}\"><span id=\"countFav\">{$amount} </span> <span>{$value['Cookbook']['cookbookname']}</span></li>"; Everything works fine so far, but now I also wanted to make sure that the amount of Elements get updated. so I need to update the $amount. So what I figured out is that with this line of code I can overwrite my HTML with the ID in my case amount $.post('../dropZone', {cookbook_id: $(this).attr('id'),id:id}, function (data) { $(amount).html(data)}); But obviously if I do this the whole li dissapears and gets replaced with the AJAX response. Does anyone got an idea how I can just update the PHP variable $amount? Thank you very much in advance. Luke --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "CakePHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~----------~----~----~----~------~----~------~--~---