本教程共三部分内容:
Nginx配合ngx_http_substitutions_filter_module模块搭建反向代理服务器,并替换目标站内容【之一】
Nginx配合ngx_http_substitutions_filter_module模块搭建反向代理服务器,并替换目标站内容【之二】
Nginx反向代理并替换内容模块ngx_http_substitutions_filter_module的使用说明
关于Nginx反向代理并替换内容模块ngx_http_substitutions_filter_module的说明:
描述 nginx_substitutions_filter 是一个nginx替换模块,就跟apache的 mod_substitute模块一样
使用示例
location / { subs_filter_types text/html text/css text/xml; subs_filter st(\d*).example.com $1.example.com ir; subs_filter a.example.com s.example.com; }
Nginx反向代理并替换内容涉及指令: * subs_filter_types
* subs_filter
subs_filter_types 语法: *subs_filter_types mime-type [mime-types] *
默认: *subs_filter_types text/html*
内容: *http, server, location*
*subs_filter_types* 是用来指定替换文件类型的 默认仅仅替换text/html类型的文件。
*如果您反代的论坛出现登录跳转源站之类的问题,请检查这个项目。
proxy_set_header Accept-Encoding “”;
subs_filter 语法: *subs_filter source_str destination_str [gior] *
默认: *none*
内容: *http, server, location*
*subs_filter* 是用来替换文本的,可以使用正则
* *g*(默认):替换匹配项。
* *i*:区分大小写的匹配
* *o*: 只匹配发现的第一个。
* *r*: 正则。
*Nginx反向代理并替换内容参考资料:
Nginx Wiki http://wiki.nginx.org/HttpProxyModule
YaoWeibin Github https://github.com/yaoweibin/ngx_http_substitutions_filter_module
本教程共三部分内容:
Nginx配合ngx_http_substitutions_filter_module模块搭建反向代理服务器,并替换目标站内容【之一】
Nginx配合ngx_http_substitutions_filter_module模块搭建反向代理服务器,并替换目标站内容【之二】
Nginx反向代理并替换内容模块ngx_http_substitutions_filter_module的使用说明
最新评论
家里挂了一个玩客云,有什么办法能电脑远程访问玩客云里图片视频,能不能回复一下我的QQ邮箱837423271@qq.com.有偿请教
666,我反而想在vps搭建smb服务端,家里PC挂载上。还想过能不能在vps同时搭个v2ray服务端,PC连上v2ray后自动内网挂载~
站长,可以直接给出一个nat类型的结论显示吗?
ubuntu 系统怎么操作呢?求问问。
右上角有个个人微信二维码 有加过的吗 我加了但是没通过,是不是博主微信
已经无法打开了!
没标出来活动什么时候结束,刚刚去看了,结束了
我比较想知道怎么联系博主…