I am stuck in a problem, whenever I submit, it is going to a blank page to execute api.
I want, it should execute API and then redirected to another page.
How can I do that,
My cshtml code is below
- @model CourseGamePlay.Dtos.StudentsDTO
- @{
- ViewBag.Title = "Admin Panel - Weeks";
- Layout = "~/Views/Shared/_adminLayout.cshtml";
- }
LOGIN
- action="/api/studentlogin">
- class="form-horizontal">class="form-group">
- @Html.LabelFor(s => s.name, htmlAttributes: new { @class = "control-label col-md-2" })
class="col-md-4">- @Html.EditorFor(s => s.name, new { htmlAttributes = new { @class = "form-control" } })
- @Html.ValidationMessageFor(s => s.name, "", new { @class = "text-danger" })
class="form-group">class="col-md-offset-2 col-md-15">- "submit" value="Login" class="btn btn-primary"/>
- @* *@
Salman BegPosted May 10, 2021, 11:11 AM