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

    I have been trying to get the submitter’s email address to show in the "from" field in the email generated by submitted forms, and I have not had any luck. The "from" email persists in defaulting to `emailsender`. My client is frustrated that they can not just click on "Reply" to respond to the emails. Here is the code:

    [!eform2db!]
    [!eForm? &formid=`ContactForm` &subject=`Email From ProtectivePackaging.net` &to=`[email protected]` &from=`email` &eFormOnBeforeMailSent=`addeform2db` &ccsender=`0` &tpl=`ContactForm` &report=`ContactFormReport` &invalidClass=`invalidValue` &requiredClass=`requiredValue` &cssStyle=`ContactStyles` &gotoid=`46` &vericode=`1` !]

    I have also tried &from=`((email))`

    I am still on Evolution
    MODx version 1.0.4
    Version codename rev 6981


    Any suggestions?
      • 742
      • 12 Posts
      Currently trying &replyto=`email` and then I will try &replyto=`[+email+]`

      More to come
        • 5340
        • 1,624 Posts
        [+email+] should work smiley
          • 742
          • 12 Posts
          Thanks for the feedback cipa! Unfortunately, &replyto=`[+email+]` did not work. huh??

          Now modifying the snippet replacing:

          ’replyto’ => isset($replyto)? $replyto:"",

          WITH

          ’replyto’ => isset($replyto)? $replyto:$_POST[’name’]."<".$_POST[’email’].">

          I have to admit, I don’t know what I am doing. I am just looking for a place where it is working, comparing the code with what I have, and making changes. I don’t intricately understand what all of the code means...*sigh*

            • 5340
            • 1,624 Posts
            HI,

            According to the documentation

            &replyto (Optional)
            Email address or fieldname containing email address Sets the email address to appear in the ReplyTo section of the email

            so

            &replyto=`email` should work if the field is named ’email’
              • 742
              • 12 Posts
              &replyto=`email` TOTALLY worked in the call - I had to check with some other recipients to see the right results.

              THANK YOU !!!