ASP.net
Awesome
Learn
Forum
Buy
Demos
Sign In
☾
☀
Switch to
Dark
Light
Mode
this site works best with javascript enabled
Ask Question
Attaching a confirm dialog to OK button of PopupFormAction
Title:
B
I
{code}
?
How do I attach some of kind of a confirm dialog, jquery, js or even the Awe().Form(), to the OK button of a PopupFormAction?
Save Changes
Cancel
Amar Duplantier
asked at 17 Jan 2014
Answers
B
I
{code}
?
you can do it with an awe popup and form like this: <%:Html.Awe().Form().FormClass("createMeal").Confirm(true).UseAjax(true).Success("suc") %> <%:Html.Awe().PopupActionLink().LinkText("create meal").Url(Url.Action("Create","SimpleMeals")).Button("Create","createmeal") %> <script> function createmeal() { $('.createMeal').submit(); } function suc() { $('.createMeal').closest('.awe-popup').dialog('close'); } </script> in the create.ascx your form needs to have the createMeal class like this: <form action="<%:Url.Action("Create") %>" class="createMeal">
Save Changes
Cancel
Omu
answered at 17 Jan 2014
please
Sign In
to leave an answer
By accessing this site, you agree to store cookies on your device and disclose information in accordance with our
cookie policy
and
privacy policy
.
OK