View Single Post
JoinedSenses
Senior Member
Join Date: Sep 2013
Old 05-05-2018 , 15:17   Re: [TF2/CSS/Any?] Regex Filter (redux)
Reply With Quote #4

Quote:
Originally Posted by T1MOXA View Post
A good plugin, but as for me it lacks whitelists for each rule.
Let's say I want to block all domains except certain.
You can add your own whitelist with negative lookbehind to allow exemptions. The config attached is just a guideline - you can write your own config or modify the one attached.

http://www.rexegg.com/regex-lookarounds.html

Lets say you wanted to add an exemption for google.com in names
here is the original
Code:
[\W\s]*[\w\-\.]+[,.]+(?:de|com|co|org|trade|me|ru|gg|tf|net)[\/]*\W*
and here is the modified
Code:
[\W\s]*[\w\-\.]+(?<!google)[,.]+(?:de|com|co|org|trade|me|ru|gg|tf|net)[\/]*\W*
If it contains the word google in front of the period, it exempts the filter.

Make sure you check out the links I attached in the original post if you're interested in learning how regex works so that maybe you can write your own .cfg file or modify the one I attached.

Last edited by JoinedSenses; 05-05-2018 at 15:20.
JoinedSenses is offline