trying to include a confirmation dialogue with my delete links

15 views
Skip to first unread message

Steven Noble

unread,
Dec 17, 2012, 7:12:15 AM12/17/12
to simple-n...@googlegroups.com
Hi there,

I'm trying to include a confirmation dialogue with my delete links.

The following creates a delete link, but leaves off the confirmation dialogue:

    category.item :delete, "Delete", category_path(@category), :method => :delete, :data => {:confirm => "Are you sure?" }

Any thoughts?

Thanks!

Steven.

Andi Schacke

unread,
Dec 17, 2012, 11:25:27 AM12/17/12
to simple-n...@googlegroups.com
https://github.com/andi/simple-navigation/wiki/FAQ#wiki-q7

Please try 

   category.item :delete, "Delete", category_path(@category), :method => :delete, :link => {:data => {:confirm => "Are you sure?" }}



Steven.

--
You received this message because you are subscribed to the Google Groups "simple-navigation" group.
To view this discussion on the web visit https://groups.google.com/d/msg/simple-navigation/-/wSA2fRAI87wJ.
To post to this group, send email to simple-n...@googlegroups.com.
To unsubscribe from this group, send email to simple-navigat...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/simple-navigation?hl=en.

Steven Noble

unread,
Dec 17, 2012, 4:21:40 PM12/17/12
to simple-n...@googlegroups.com
Thanks. Sorry I missed that one. I was searching too literally for "confirm" options rather than generally for the ability to modify the link.

Steven.
---
Steven Noble
Founder & CEO, Testivate
http://testivate.com | +61 (0) 4 0404 1928 | http://snoble.net

Reply all
Reply to author
Forward
0 new messages