We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 36426
    • 197 Posts
    Hi I hope someone can please help.

    I'm using Formz or Formz Builder which uses FormIt. I've made 2 or 3 different contact forms for different areas of my site.

    It works well but when I receive an enquiry I can't just click 'Reply' as it uses my own email as the Sender or From address.

    I wondered if anyone could please help it use the Email from the contact form, the person sending the email?

    I tried adding the following to my formTpl :

    &emailFrom=`[[+From]]`


    which didn't work. I also tried:

    &emailFrom=`[[+field14]]`


    but that didn't work either, plus if the above had worked it wouldn't of been ideal as field14 may be an email on one form, but on a different form it has a different ID...

    I just need FormIt to look for an email field and have it reply there. Or be able to add the label as just 'Email' so it matches on all forms...

    Thank you very much for any help.
      Yorkshire UK based hosting provider: https://www.simulant.uk
      • 42046
      • 436 Posts
      If you don't specify &emailFrom in your FormIt call, it will automatically look for a form field named "email" and use that address, failing that it will use the emailsender system setting.

      Form email field should look something like:

      <input type="text" name="email" id="email" value="[[!+fi.email]]" />
        • 36426
        • 197 Posts
        Hi thanks for the reply but on checking the page source my email box on the form is like this:

        <label for="field14" title="Field14">Email *</label>
        <input type="text" name="field14" id="field14" value="" class="text " size="40" />
        


        On another page the form has the email entry as this:

        <label for="field13" title="Field13">Email *</label>
        
          <input type="text" name="field13" id="field13" value="" class="text " size="40" />


        How can I set up FormIt to use either of these or edit these fields to work instead?

        Thank you again for any help with this.
          Yorkshire UK based hosting provider: https://www.simulant.uk
          • 4172
          • 5,888 Posts
          If possible, build you form manually without formz as usual.
          Then its possible to set the emailFrom within a formit-hook or by using the getReqParam-snippet or fastField-Post-tag to set the property by the posted email-value.
            -------------------------------

            you can buy me a beer, if you like MIGX

            http://webcmsolutions.de/migx.html

            Thanks!
            • 36426
            • 197 Posts
            Hi thanks. I've already set up lots of Forms with Formz Builder unfortunately! I wondered I've checked with their GitHub and there seems to be a bug open for this so I've added my request for help there also.

            Formz interface does accept hooks.

            You can add additional hooks using comma-separator to call on your FormIt form. e.g. redirect,spam

            Could this be used to call a hook for changing the email name to become 'email' somehow?

            Thanks again.
              Yorkshire UK based hosting provider: https://www.simulant.uk
            • If Formz uses the default FormIt hooks: Try &emailReplyTo=`[[+email]]` if you have an input with the name attribute email in your form where the web user could insert the email address.
                • 36426
                • 197 Posts
                Hi thanks. I've put:

                &emailReplyTo=`[[+field14]]`


                In the 'Hooks' box but emails are still coming through as the default sender and clicking Reply from the email just uses the same default sender as before... I also tried adding the above in the 'Properties' box too (Additional properties that a FormIt form can take, you can add multiple properties using the double pipe || e.g.: &fiarTpl) - but again this hasn't worked either... Is there something I'm missing?
                  Yorkshire UK based hosting provider: https://www.simulant.uk
                  • 42046
                  • 436 Posts
                  Can you not manually edit the form so it contains more standard FormIt labeling?

                  <input type="text" name="email" id="email" value="[[!+fi.email]]" />
                    • 4172
                    • 5,888 Posts
                    if you know the email-field is 'field14'

                    you can try

                    &emailReplyTo=`[[!getReqParam? &name=`field14` &type=`POST`]]`


                    you need to have getReqParam installed, of course
                      -------------------------------

                      you can buy me a beer, if you like MIGX

                      http://webcmsolutions.de/migx.html

                      Thanks!
                    • Maybe I have misunderstood your needs:

                      &emailReplyTo changes the Reply-To header of the email sent with the email hook. If you click on 'reply to' in your mail application, you could answer to that address. The From header is not changed, since on a lot of hosts you can't send emails by php mail function with a from address that does not belong to the installation.