urlrewriter2.6在java中的应用 URL重写

阅读更多

http://xiaopihai.iteye.com/blog/384386  Java中urlrewriter的使用
urlrewriter:  url重写
下载: http://tuckey.org/urlrewrite/dist/urlrewritefilter-2.6.zip

在web.xml中初始化:

UrlRewriteFilter
org.tuckey.web.filters.urlrewrite.UrlRewriteFilter


UrlRewriteFilter
/*


methor 为get的访问地址:http://localhost:8081/ajax-struts1.2/login.do?name=5e&pass=er
从form提交的url重写:


  
  
  


method为post的访问地址:http://localhost:8081/ajax-struts1.2/login.do

post">
 
 
 

对应:

 ^/(\w+).html
 /$1.do

访问http://localhost:8081/ajax-struts1.2/login.html,会转向login.do


http://l530.spaces.live.com/PersonalSpace.aspx?_c11_BlogPart_n=1&_c11_BlogPart_handle=cns!9D9533B86846A992!

152&_c=BlogPart

  • urlrewritefilter-2.6.zip (136.2 KB)
  • 下载次数: 17

你可能感兴趣的:(Java,Ajax,Web,HTML,XML)