Jsp auto forwarding
How I can to make auto forwarding from any dir to .jsp page with params, such as:
http://site.net/foo/ -> http://site.net/show.jsp?p=foo
http://site.net/foo2/ 开发者_运维技巧-> http://site.net/show.jsp?p=foo2
http://site.net/foo3/ -> http://site.net/show.jsp?p=foo3
http://site.net/foo4/ -> http://site.net/show.jsp?p=foo4
You can use UrlRewriterFilter to achieve this (MVC independent, since I don't know how you're implementing your webapp).
If you are using your app server behind Apache you can achieve this with mod_rewrite.
http://httpd.apache.org/docs/current/mod/mod_rewrite.html
精彩评论