What is the correct way to use Mappings in Spring Annotations? While submitting forms sometimes it happened that form is sumitted to /controller_name/store and sometimes to /store . How do I manage such errors. Where am I going wrong?
我的猜测是,这是由于JSP中混合了绝对链接和相对链接/路径,和/或未考虑“当前”页面和您要访问的页面的相对位置而引起的。
It depends on your html form action
tag. When it is start with /
, your form data will go to http://domain/{ACTION}
, when action is without /
it will be appended to site current address.
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.