0

I want to exclude some urls from Live HTTP headers (firefox add-on).
so in Config area i checked Exclude URLs With regex and put the string below in it:

.gif$|.jpg$|.ico$|.css$|.js$|.png$|.bmp$|.jpeg$|google$|bing$|alexa$

i want to remove all images from capturing and any url that contains :
css - js - google - bing - alexa
what is the problem about my regex and would you please fix it for me?

thanks in advance

4

1 回答 1

1
  • .意思是“任何字符”
  • $意思是“字符串的结尾”

那说:

  • .gif$将匹配“任何以它结尾的字符串gif至少有 4 个字符长”
  • google$将匹配“任何以结尾的字符串google

我猜你正在寻找类似的东西:

[.](gif|jpg|ico|css|js|png|bmp|jpeg)$|\b(google|bing|alexa)\b

也许您的正则表达式会被您正在使用的工具^自动锚定。$在这种情况下,请.*另外使用:

.*[.](gif|jpg|ico|css|js|png|bmp|jpeg)$|.*\b(google|bing|alexa)\b.*
于 2013-05-16T07:31:01.540 回答