The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Wildcard in email filters subject, etc.?

Discussion in 'E-mail Discussions' started by Kira, Jul 3, 2017.

Tags:
  1. Kira

    Kira Registered

    Joined:
    Jul 3, 2017
    Messages:
    3
    Likes Received:
    2
    Trophy Points:
    3
    Location:
    Greenville, SC
    cPanel Access Level:
    Reseller Owner
    Greetings!

    I am trying to filter out emails with subjects such as "Lose 25 pounds" or "Burn 123 calories," which change every time to "Lose 10 pounds," etc. Can I use a wildcard in email filters for the numbers? I've tried Subject contains Lose * pounds and that doesn't work. Neither does Subject contains Lose % pounds. Did I miss a document page somewhere or is this just not possible and maybe use regex? Please advise.

    Thanks in advance.

    ~Kira
     
  2. Jcats

    Jcats Well-Known Member

    Joined:
    May 25, 2011
    Messages:
    588
    Likes Received:
    88
    Trophy Points:
    153
    Location:
    New Jersey
    cPanel Access Level:
    DataCenter Provider
  3. Jcats

    Jcats Well-Known Member

    Joined:
    May 25, 2011
    Messages:
    588
    Likes Received:
    88
    Trophy Points:
    153
    Location:
    New Jersey
    cPanel Access Level:
    DataCenter Provider
    or this might be better in case the spammer decides to drop his proper writing skills and go with lower case ;)

    Code:
    ^[Ll]ose \d+ [Pp]ounds$
     
  4. Kira

    Kira Registered

    Joined:
    Jul 3, 2017
    Messages:
    3
    Likes Received:
    2
    Trophy Points:
    3
    Location:
    Greenville, SC
    cPanel Access Level:
    Reseller Owner
    Thanks!!

    lol there are no proper writing skills to drop, in most cases : )

    What about getting error messages such as this one, when testing filters.
    This filter is no longer than any others that I can see, is there a character limit or ?

    Pattern = \b[A-Z0-9._%+-]+@[A-Z0-9.-]+\.stream\b
    **** debug string too long - truncated ****

    I am getting the **truncated** message on some other filters also.
    **** debug string too long - truncated ****
    ) or $message_body contains our pill
    and then it goes on with the 3 more messages for the wildcards I had input, which I'm going to delete.
     
  5. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    37,173
    Likes Received:
    1,295
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    Hello,

    This error message should not impact the filter itself. As I understand, it's referring to a limit related to Exim's debugging functionality. That said, you could try browsing to "WHM >> Exim Configuration Manager >> Advanced Editor" and increasing the value for the "message_body_visible" option to avoid this error message.

    Thank you.
     
  6. Kira

    Kira Registered

    Joined:
    Jul 3, 2017
    Messages:
    3
    Likes Received:
    2
    Trophy Points:
    3
    Location:
    Greenville, SC
    cPanel Access Level:
    Reseller Owner
    Maybe it's because I have too many things to check for in one filter.
    I'll break those up a bit.
    Thanks so much for all your help!!

    Everyone have a happy and safe 4th : )
     
    Jcats and cPanelMichael like this.
Loading...

Share This Page