[英]manage mappings in Spring MVC
What is the correct way to use Mappings in Spring Annotations? 在Spring注释中使用映射的正确方法是什么? While submitting forms sometimes it happened that form is sumitted to /controller_name/store and sometimes to /store .
在提交表单时,有时会将表单赋值给/ controller_name / store ,有时又赋给/ store 。 How do I manage such errors.
如何处理此类错误。 Where am I going wrong?
我要去哪里错了?
我的猜测是,这是由于JSP中混合了绝对链接和相对链接/路径,和/或未考虑“当前”页面和您要访问的页面的相对位置而引起的。
It depends on your html form action
tag. 这取决于您的html表单
action
标签。 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. 当以
/
开头时,您的表单数据将转到http://domain/{ACTION}
,而没有/
动作将被附加到站点当前地址。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.