Nevermind, AD7six post explains it well and very better (and included
my note, but post alone seems not to be sufficient anyway)

On Nov 14, 1:27 pm, "j0n4s.h4rtm...@googlemail.com"
<j0n4s.h4rtm...@googlemail.com> wrote:
> Another possibility is adding delete links within a <form> that has
> method = post,
> check the request method (if its POST) on the action as well.
>
> in addition: give that form a class and css stylize it down to a link
> (though why not keep it a button, buttons = post, links = get paradigm
> works well too)
>
> On Nov 13, 4:55 pm, Jeremy Burns <jeremybu...@me.com> wrote:
>
> > Thanks - good approach.
>
> > Jeremy Burns
> > jeremybu...@me.com
> > (Skype) +44 208 123 3822 (jeremy_burns)
> > (m) +44 7973 481949
> > (h) +44 208 530 7573
>
> > On 13 Nov 2009, at 15:44, Marcelo Andrade wrote:
>
> > > On Fri, Nov 13, 2009 at 4:14 AM, jburns <jeremybu...@me.com> wrote:
> > >> I am not happy with the javascript delete confirm method, as it
> > >> doesn't appear if javascript is disabled and the delete happens with
> > >> no checking. I want to ask the user to confirm that he wants to delete
> > >> a record, and would like to do something like this:
>
> > >> 1. User clicks a delete link, which points at the delete action.
> > >> 2. The delete action redirects the user to the view screen for the
> > >> record with a flash message asking him to confirm the delete, and
> > >> links to confirm or reject the deletion.
> > >> 3. If the user clicks the confirm link they are redirected back to the
> > >> delete action but this time with a parameter that shows the action has
> > >> been confirmed, and the deletion takes place.
> > >> 4. The parameter identified in (3) is not present in stage (2), which
> > >> is how (2) knows to direct to the view screen and ask for
> > >> confirmation, rather than just processing the delete.
> > >> 5. I am reusing the view screen and action in (2) so that I don't have
> > >> to build new confirm_delete screens and actions (I would need to build
> > >> about 60 of them).
>
> > > It's not so hard to do it with ordinary $html->link.
> > > Point the delete link to a question action that do what
> > > you want (a link to the real delete action and another
> > > to go back).
>
> > > If you can realize how to do it this way, so you could
> > > encapsulate the all stuff creating your own helper,
> > > overriding the $html->link method.
>
> > > Best regards.
>
> > > --
> > > MARCELO DE F. ANDRADE
> > > Belem, PA, Amazonia, Brazil
> > > Linux User #221105
>
> > > --
>
> > > You received this message because you are subscribed to the Google Groups 
> > > "CakePHP" group.
> > > To post to this group, send email to cake-...@googlegroups.com.
> > > To unsubscribe from this group, send email to 
> > > cake-php+unsubscr...@googlegroups.com.
> > > For more options, visit this group 
> > > athttp://groups.google.com/group/cake-php?hl=.

--

You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to cake-...@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=.


Reply via email to