


方法仅供参考,若有失效,建议联系程序开发商在核实下具体方法
1、下载解压后将 UrlRewriteFilter 上传到WEB-INF/lib目录内
编辑WEB-INF/web.xml 在其它servlet mapping前加入如下代码:
3、在WEB-INF下新建urlrewrite.xml文件,加入跳转规则【把blog.tag.gg修改成自己的域名】<filter>
<filter-name>UrlRewriteFilter</filter-name>
<filter-class>org.tuckey.web.filters.urlrewrite.UrlRewriteFilter</filter-class>
</filter>
<filter-mapping>
<filter-name>UrlRewriteFilter</filter-name>
<url-pattern>/*</url-pattern>
<dispatcher>REQUEST</dispatcher>
<dispatcher>FORWARD</dispatcher>
</filter-mapping>
注意,若设置后出现循环重定向,需检查您的https头是多少,可将如上代码中的 From-Https 改成 Https 再试下,<urlrewrite>
<rule>
<name>https redirect</name>
<condition name="From-Https" operator="notequal">^on</condition>
<from>^/(.*)</from>
<to type="permanent-redirect" last="true">https://blog.tag.gg/$1</to>
</rule>
</urlrewrite>



亲爱的:若该文章解决了您的问题,可否收藏+评论+分享呢?
文章评论 本文章有个评论