nginx-正则表达式-重定向

匹配任何html结尾的访问,然后重定向到http

rewrite ^(.*)\.html$ http://10.86.255.119$request_uri;

匹配任何index?这样的参数,然后重定向到相应的http

 rewrite ^(.*)index\.php\?$ http://10.86.255.119$request_uri;

猜你喜欢

转载自www.cnblogs.com/yangxueyou/p/8973630.html