We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 14723
    • 7 Posts
    Hi,

    I’ve read this topic (http://modxcms.com/forums/index.php/topic,53635.0.html) which seems to be the solution to my question.
    However, i don’t understand what the author achieved....

    1/ what’s the ’senddirect’ parameter, i can’t find any documentation on it in the Eform wiki
    2/ same goes for ’mailselector’.

    What i want my form to do: sending to a different e-mail recipient based on 1 or 2 choices made in the form.
    I hope someone can help me out here. Thanks in advance.


    EDIT:
    Seems like i was looking at an old version of the Wiki. (http://wiki.modxcms.com/index.php/EForm#eForm_Document_Snippet_Calls)

    So i’ve done a little reading, and it seems the thing i’d like to achieve can not be done with &mailselector.

    If user clicks an option in dropdown A, mail has to be sent to recipient A.
    If user clicks an option in dropdown B, mail has to be sent to recipient B
    if user clicks options in both dropdown A and B, mail has to be sent to recipient A.

    Any thoughts?

      • 4310
      • 2,310 Posts
      This might help, in the documentation within assets/snippets/eform/docs/
      &mailselector (Optional)
      Sets the name of the form field to use as a selector to select a single email from the comma (,) delimited emails assigned the &toparameter. This selector field will act like a numeric index to select an email. It will start at 1 for the first email and ends at N for the last email in the list.

      For example: &to =`[email protected],[email protected],[email protected]` &mailselector=`topic`

      On the web form the topic fields is actually a dropdown menu. when the user selects a topic from the list the value 1,2 or 3 will be sent to eForm which will then be used to select one of the three emails assigned to the &toparameter. This email address will be the address used to send the email to.
        • 14723
        • 7 Posts
        Thanks. This would be a solution in any other case, but i have to use multiple input fields. Mailselector only allows for one.

        I’ve decided to take this another route. Probably by filtering in a Gmail account and then forward to the right e-mail address.