NGINX
NGINX Trac
3rd Party Modules
Security Advisories
CHANGES
OpenResty
ngx_lua
Tengine
在线学习资源
NGINX 开发从入门到精通
NGINX Modules
ngx_echo
alpinefly
V2EX  ›  NGINX

nginx 的 subs_filter 模块怎么使用正则替换

  •  
  •   alpinefly · May 9, 2018 · 4423 views
    This topic created in 2994 days ago, the information mentioned may be changed or developed.
    各位大牛,使用 subs_filter_module 替换广告,例如 sub_filter '<div id="menu">' '<div id="menu" style="display:none;">';
    现在一堆 div[id="ad_***"] 内容,想使用正则表达式写,sub_filter '<id="ad_***">' '<id="ad_***" style="display:none;">';div id^="ad_"]
    想这种,请教怎么写?
    No Comments Yet
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   5584 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 51ms · UTC 08:07 · PVG 16:07 · LAX 01:07 · JFK 04:07
    ♥ Do have faith in what you're doing.