I am doing a mysql database search and retrieving some results via ajax livesearch using the example on w3schools and i want to manipulate those results (drag and drop them) but im having a problem because the script loads before you enter the search and get the results so it does absolutely nothing no the search results. Any thoughts on this matter ?
I am doing a mysql database search and retrieving some results via ajax livesearch
Share
Ah – thanks for the clarification.
The elements you want to drag are being created after the drag/drop initialization. You need make them draggable:
for example, add ‘dragMe’ as a class to the items. Once the list is populated from the server, then make those items dragable:
I would really look into jQuery’s ajax functions and their autocomplete
To clarify and for jquery (against your cited example):
In your php, change your display so it is blocks that can be dragged.
past that, you’ll really want to do some more research to get a better idea of whats going on.