I want a tag that basically performs a post action on my razor page model including a parameter. Ideally I don't want to have a form around it and have the linking to the according action in the href="post-to-action"
in MVC I was always able to call a controller action without having a form around a button/ with the following:
<a href="@Url.Action("Information", "Admin", new { id = UrlParameter.Optional })">Add an Admin</a>
This doesn't work for razor pages im pretty sure. Im struggling to find an alternative in razor pages. Of course ajax is an option but I didn't find an alternative to make a post call in razor pages without having a around it.
Does anybody have a workaround without having to submit a form with javascript or something along those lines?