Hey, Seems like you have a couple of options...
1. you could just write normal javascript irrespective of lift and just put that in a JS file like normal. Something like: $('#mybutton').click(function(e){ confirm... //blah blah code here }); 2. If you *really* want to use the on-click handler (personally I wouldn't) then you could do somethig like this in your snippet: SHtml.ajaxButton("submit", () => println("badger")) % ("onclick" -> "confirm(....);") I would highly recommend using option one as the functionality is purely a client side concern in that sense and nothing to do with lift. Does that help? Cheers, Tim On Apr 27, 11:29 pm, Chris <cfor...@gmail.com> wrote: > Hi there, > I'm pretty new to Lift and Scala for that matter, but have long been > on the lookout for something like seaside running on the JVM and this > is just great! Now to my issue... > I've hit a brick-wall in the attempt to get a confirmation dialog > working before executing an ajaxButton. I've tried adding an "onclick" > attribute to the ajaxButton call, but that only seems to replace the > AJAX call itself rather than say prepending the call with the contents > of the "onclick" attribute. I'd like to implement a "delete" button > with a confirmation dialog. I've looked at ModalDialog, but due to my > inexperience and lack of examples haven't found a way of achieving > this. Could someone enlighten me as to how I could implement this? > Cheers, Chris. > PS: I hope this isn't a FAQ but I've searched this group and the web > on the matter, but haven't found an answer, so sorry in advance if > this has been answered before. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Lift" group. To post to this group, send email to liftweb@googlegroups.com To unsubscribe from this group, send email to liftweb+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/liftweb?hl=en -~----------~----~----~----~------~----~------~--~---