We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 47775
    • 16 Posts
    Hello !
    my problem is that i already instal formIt. i created my form in modx i call the formit in my form page. i declared a as the following:
    [[ &hooks=`email`
    &emailTpl=`myTemplate`
    &emailForm=`[[+field#]]`
    &emailTo=`myemail`
    ]]
    I placed this snippet call in the same place witch i want my form to appear.
    but when i send message i could not receive any message in my email .
    Thanks.
      • 28042 ☆ A M B ☆
      • 24,524 Posts
      Is that the exact FormIt snippet call on your page?
        Studying MODX in the desert - http://sottwell.com
        Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
        Join the Slack Community - http://modx.org
        • 47775
        • 16 Posts
        See the following is a copy past of my snippet call;
        [[!FormIt?
        &hooks=`email`
        &emailTpl=`messageContentTpl`
        &emailFrom=`[[+field#]]`
        &emailTo=`[email protected]`
        ]]

          • 28042 ☆ A M B ☆
          • 24,524 Posts
          That &emailFrom =`[[+field#]] doesn't look right, where did you see that used?

          Are you sure that email sending is enabled on your server? You can troubleshoot email functions with BobRay's excellent QuickEmail tool.
            Studying MODX in the desert - http://sottwell.com
            Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
            Join the Slack Community - http://modx.org
            • 28042 ☆ A M B ☆
            • 24,524 Posts
            Ok, that looks like you use FormZ. If that is correct, then the # in the [[+field#]] should actually be the number of the field, like [[+field2]] if your email field is field2.
              Studying MODX in the desert - http://sottwell.com
              Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
              Join the Slack Community - http://modx.org
              • 47775
              • 16 Posts
              I m not using fromz i m using fromIt
                • 47775
                • 16 Posts
                so i should not include the &emailFrom =`[[+field#]]
                  • 28042 ☆ A M B ☆
                  • 24,524 Posts
                  Use the name of the actual field in the table. Usually the email field is named "email", so you would use [[+email]].
                    Studying MODX in the desert - http://sottwell.com
                    Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
                    Join the Slack Community - http://modx.org
                    • 47775
                    • 16 Posts
                    Could you in short show me the procedure to create a contact form with fromIt because i lost the way?
                    Thanks
                      • 28042 ☆ A M B ☆
                      • 24,524 Posts
                      The FormIt snippet:
                      [[!FormIt?
                         &hooks=`spam,email`
                         &emailTpl=`formMailTpl`
                         &emailSubject=`Website Contact`
                         &emailTo=`[email protected]`
                         &emailFrom=`[[++emailsender]]`
                         &emailFromName=`[[++site_name]]`
                         &emailReplyTo=`[[+email]]`
                         &emailReplyToName=`[[+name]]`
                         &successMessage=`Thank you. Your message has been sent.`
                         &validate=`name:required,
                            email:email:required,
                            text:required:stripTags`
                      ]]

                      The form:
                      [[!+fi.error_message:notempty=`<div><p class="notice error">[[!+fi.error_message]]</p></div><hr>`]]
                      [[!+fi.successMessage:notempty=`<div><p class="notice success">[[!+fi.successMessage]]</p></div><hr>`]]
                      
                      <form action="[[~[[*id]]]]" method="post" class="contactform">
                              <label [[+fi.error.name:isnot=``:then=`class="error"`]] for="name">Name: [[!+fi.error.name]]</label>
                              <input [[+fi.error.name:isnot=``:then=`class="error"`]] type="text" name="name" id="name" value="[[!+fi.name]]">
                       
                              <label [[+fi.error.email:isnot=``:then=`class="error"`]] for="email">Email:[[!+fi.error.email]]</label>
                              <input [[+fi.error.email:isnot=``:then=`class="error"`]] type="text" name="email" id="email" value="[[!+fi.email]]">
                       
                              <label [[+fi.error.text:isnot=``:then=`class="error"`]] for="text">Message: [[!+fi.error.text]]</label>
                              <textarea [[+fi.error.text:isnot=``:then=`class="error"`]] name="text" id="text" cols="55" rows="7">[[!+fi.text]]</textarea>
                       
                         	<button type="submit">Submit</button>
                      </form>
                        Studying MODX in the desert - http://sottwell.com
                        Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
                        Join the Slack Community - http://modx.org