I am working with a project in C#, MVC , asp.net and I want my form on success to add a new button.
@using (Ajax.BeginForm("CreatePaper", "AdminPaper", "Post", new AjaxOptions { OnSuccess = "Success" }))
{
//some fields to complete
<button id="submiter" type="submit" class="btn btn-primary">Create</button>
}
@section scripts
{@Scripts.Render("~/bundles/jqueryval")
<script type="text/javascript">
function Success() {
console.log("test");//did not know how to add the button, maybe I can use ajax?
}
</script>
}
how can I add a new button next to the "submiter" button?thanks
Note> for some reason I can not see the log in the console. It is not showing anything.