I'm fairly sure I'm missing something very practical but I'm floundering at finding it online.
How do you pass information from the view to the controller without using URL items (query strings, /variable/ etc?
The easiest scenario I can think that surely must have an example is a simple set of login credentials handed to a controller. Naturally you wouldn't want the username / password to be viewable in the URL.
You can POST data to the controller, so that it doesn't appear in the URL. See this blog post for details.
The basic steps are:
[AcceptVerbs(HttpVerbs.Post)]
attribute to the action.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.