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.

EXIM Custom Filter Assistance

Discussion in 'E-mail Discussions' started by vinoth sundararajan, Apr 26, 2017.

  1. vinoth sundararajan

    Joined:
    Mar 1, 2017
    Messages:
    10
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    chennai
    cPanel Access Level:
    Root Administrator
    Twitter:
    Hi,

    I want to use make an incoming and outgoing copy for only 5 id's in my exim filter
    Code:
    if first_delivery
    and ("$h_to:" contains "admin@xyz.com,ravi@xyz.com,clothing@xyz.com")
    then
    unseen deliver "deep@xyz.com"
    unseen deliver "kalpesh@xyz.com"
    unseen deliver "mitesh@xyz.com"
    unseen deliver "admin@xyz.com"
    endif
    
    kindly suggest on this.
     
    #1 vinoth sundararajan, Apr 26, 2017
    Last edited by a moderator: Apr 26, 2017
  2. km9

    km9 Member

    Joined:
    Apr 5, 2017
    Messages:
    15
    Likes Received:
    2
    Trophy Points:
    3
    Location:
    Asia
    cPanel Access Level:
    Root Administrator
    The syntax is not quite right, and testing just the "To:" header will deliver copies of all mail that is specifically addressed to those destinations. (not cc'd or bcc'd)

    Want to save all outgoing email to read later...

    I think you may want something more along the lines of:

    if ("$h_to:, $h_cc:, $h_bcc" contains "uvw@domain.com")
    or ("$h_to:, $h_cc:, $h_bcc" contains "xyz@domain.com")
    then ...

    You might also want to include some error checking in case any delivery fails. See 'noerror'

    3. Exim filter files

    or 'errors_to'.

    15. Generic options for routers
     
  3. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

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

Share This Page