whoa hang on -
http://groups.google.com/group/cake-php/browse_thread/thread/8de4714f1a04a97b/fd8011bfed27c381?lnk=gst&q=mootools#fd8011bfed27c381

I should have searched mootools on here before! (tried google...but
not the group search!)

On Dec 6, 10:24 am, luke BAKING barker <[EMAIL PROTECTED]> wrote:
> Hi Adam,
>
> thanks for your replies. In fact I am using mootools for the nested
> drag and drop sortable - I am not sure there is an equivalent in
> Scriptaculous although it should be possible. Mootools and Prototype
> are not compatible however. Your example has given me a bit of an idea
> of the best way of naming my lists and items however!
>
> can anyone else point me in the direction of documentation/tips on
> serializing Ajax data with Cake ?
>
> cheers
>
> Luke
>
> On Dec 6, 4:57 am, Adam Royle <[EMAIL PROTECTED]> wrote:
>
> > I forgot to mention you need to include the prototype+scriptaculous
> > javascript libraries - this is what the ajax helper uses.
>
> > Adam
>
> > On Dec 6, 2:57 pm, Adam Royle <[EMAIL PROTECTED]> wrote:
>
> > > here is my code for the view using the ajax helper (note the ids are
> > > important, these are actually the ids that exist in the database)
>
> > > <ul id="items">
> > >         <li id="item_1">Item 1</li>
> > >         <li id="item_2">Item 2</li>
> > >         <li id="item_3">Item 3</li>
> > > </ul>
>
> > > <?php echo $ajax->sortable('items', array('constraint' => false,
> > > 'url'=>'/myitems/updaterank/')); ?>
>
> > > and now the code in the myitems controller:
>
> > > function updaterank()
> > > {
> > >         foreach ($this->params['form']['items'] as $rank => $id){
> > >                 $this->MyItem->id = $id;
> > >                 $this->MyItem->saveField('rank',$rank);
> > >         }
> > >         $this->autoRender = false;
>
> > > }
>
> > > Cheers,
> > > Adam
>
> > > On Dec 6, 4:19 am, luke BAKING barker <[EMAIL PROTECTED]> wrote:
>
> > > > Hi
>
> > > > I am building a little menu manager for a backend of a site. I am
> > > > using this Nestable Sortable drag and drop script , using mootools
> > > > framework.
> > > > demo and script:http://youmuppet.com/?page_id=9
> > > > description:http://forum.mootools.net/viewtopic.php?id=1106
>
> > > > It essentially allows the reordering of a <OL>'s <LI>'s and nested
> > > > <OL>s , and does it very nciely.
>
> > > > I want to allow the user to re-order the list as they want the "tree"
> > > > to be, then hit a Submit button, which will post this and update all
> > > > the items in the database with their new order. I know this involves
> > > > serializing the data, but am asking for a few pointers on finding out
> > > > how to do this, with particular reference to the most Cake way(s) of
> > > > doing this?
>
> > > > I havent any experience really with AJAX in CakePHP, and didnt want to
> > > > steam ahead and miss out any of the goodness there may be!
>
> > > > thanks for any help you may be able to give,
>
> > > > Luke
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Cake 
PHP" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to