I want to display loading animation when the user clicks on submit button. Simple gif will do the job. This is my code:
@using (Html.BeginForm(\"SData\",\"Crawl\
Hello I just read your post here and it worked fine for me in .net core 2.1 using Microsoft.AspNetCore.Mvc:
@using (Html.BeginForm("ActionName", "ControllerName", FormMethod.Post, new {id="UpdateForm"})) {@Html.AntiForgeryToken()
your inputs here...}
then the HTML script:
$("#UpdateForm").submit(function(e){$("#your loader gif here..")}
if you have problems you might want to debug your Action Method and see if it breaks inside the statement.... @Dr Freeman: you are able to redirect to any view as follows:
return RedirectToAction("ActionName", new {@id=id});
Hope this help