Block emails with a subject of "Re:" RSS Back to forum
@Toby Miletta:
You can use a regular expression Keyword Blacklist filter with Subject scope against these as:
^Re:$
I hope this helps. The ^ and $ symbols act as "anchors", basically forcing the regular expression to match only if the subject line is exactly "Re:", with no preceeding or following characters.
@Toby Miletta: I am glad to hear that. If we can be of any further assistance, do not hesitate to contact us.
not to threadjack or anything, but along this exact same line, i would like to be able to regex for this:
match this: "re:anything"
not match this: "re: anything"
notice the space - anything without a space after the colon (:) is always spam... and on the off chance that one might be legit, who cares we dont want email from people who have a thing against the space bar
@Bryon Humphrey:
This can be achived using:
^Re:\S.*
This will match any strings beginning with "Re:" ("^Re:"), followed by a non-whitespace character ("\S") and followed by zero or more arbitrary characters (".*"). The tricky part is "\S": this requires a character to be present after "Re:", but the regex will match only if it not a whitespace-class character. Whitespace characters include Space, Tab and Line-Ends, so if you are specifically looking for the Space character only, you can substitute "[^ ]" (note the whitespace after ^) for "\S", or a bit more elegantly "[^\x20]", where \x20 is the "ASCII" code of the space character in hexadecimal notation.
An excellent guide to Regular Expressions is available at http://www.regular-expressions.info/tutorial.html
We are receiving many emails with the subject of just “Re:”. These messages are clearly spam. How can I block all emails with the subject of just “Re:” and not block any legit emails with “Re: (Message Subject)”?
Thanks