Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <% using (Ajax.BeginForm("Contact", "AboutUs", new AjaxOptions()
- {
- OnBegin = "submitComments_begin",
- OnSuccess = "submitComments_success",
- OnFailure = "submitComments_failure",
- OnComplete = "submitComments_complete",
- LoadingElementId = "submitting"
- }, new { id="fooForm" }))
- Request["__MVCASYNCPOST"] = "true"
- Request.IsAjaxRequest()
- public static bool IsAjaxRequest2(this HttpRequestBase request)
- {
- return !string.IsNullOrEmpty(
- request.Params["__MVCASYNCPOST"] as string);
- }
Add Comment
Please, Sign In to add comment