[Phpwm] RE: Phpwm Digest, Vol 41, Issue 6

Chris Allen pickledegg at hotmail.co.uk
Fri Nov 3 12:00:39 GMT 2006


>Chris,
>if you get stuck then just give me a shout, its a while since I wrote that
>bit but I should be able to review just how I did it pretty quickly.
>I dont recall it taking me hugely a long time to get it sorted once I'd
>worked out what it was supposed to do.
>One thing that I do recall was afterwards figuring that in fact you didnt
>actually technically need two buttons, just a down one - since you could
>always drop down the one above the one you wanted to go up to get the same
>result.
>Didnt look quite as intuitive for the user though as up/down buttons!

Well have a look at this:
I've gone with the Ajax solution, but as I've never used ajax before I have 
a question.

http://www.pickledegg.orchardhostings6.co.uk/cmf/index.php/admin/

( just the draggable bit-  its all WIP ) :-)


In the article where I got it from ( 
http://www.phpriot.com/d/articles/client-side/sortable-lists-with-php-and-ajax/index.html 
), he mentions this:

"One possible way to handle this would be to send a success/failure 
indication from processor.php, and then to read this response in index.php, 
rolling back the drag and drop if failure was returned."

Do you have any idea how he would 'roll back' the drag and drop if a failure 
was returned?

PS, I got it working and transferred it to a codeigniter environment, that 
why the urls look the way they do.

If you want any of the code, just yell.

_________________________________________________________________
Windows Live™ Messenger has arrived. Click here to download it for free! 
http://imagine-msn.com/messenger/launch80/?locale=en-gb




More information about the Phpwm mailing list