We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 36969
    • 54 Posts
    I can't seem to get FormIt to work correctly for me. Thought I would post my issue to see what feedback I get. I have gone by the instructions and removed the html from the template and put the [[*content]] in it's place. On the resource page in the content area, here is the code for the snippet and the html"

    <p>[[!FormIt? &hooks=`email` &emailTpl=`sentEmailTpl` &emailSubject=`Message From Contact Form` &emailTo=`[email protected]` ]]</p>
    <p>Please fill out the form below and submit to request more information.</p>
    <p> </p>
    <h4 class="colr heading">Leave us a message</h4>
    <p><input id="nameBox" class="bar" onfocus="if(this.value == 'Name') { this.value = ''; }" onblur="if(this.value == '[[!+fi.contact_name]]') { this.value = 'Name'; }" type="text" name="s" value="Name" /> <input id="bnameBox" class="bar" onfocus="if(this.value == 'Business Name') { this.value = ''; }" onblur="if(this.value == '') { this.value = 'Business Name'; }" type="text" name="s" value="Business Name" /> <input id="EmailBox" class="bar" onfocus="if(this.value == 'Email') { this.value = ''; }" onblur="if(this.value == '') { this.value = 'Email'; }" type="text" name="s" value="Email" /> <input id="PhoneBox" class="bar" onfocus="if(this.value == 'Phone') { this.value = ''; }" onblur="if(this.value == '') { this.value = 'Phone'; }" type="text" name="s" value="Phone" /></p>
    <div class="clear"> </div>
    <p><textarea name="s" rows="5" cols="">Message
      • 36969
      • 54 Posts
      Also I'm not sure how to post all my code in a thread here... It's obviously not showing up!
        • 4172
        • 5,888 Posts
        Quote from: dgroppen at May 24, 2012, 11:50 AM
        I can't seem to get FormIt to work correctly for me. Thought I would post my issue to see what feedback I get. I have gone by the instructions and removed the html from the template and put the [[*content]] in it's place. On the resource page in the content area, here is the code for the snippet and the html"

        <p>[[!FormIt? &hooks=`email` &emailTpl=`sentEmailTpl` &emailSubject=`Message From Contact Form` &emailTo=`[email protected]` ]]</p>
        <p>Please fill out the form below and submit to request more information.</p>
        <p> </p>
        <h4 class="colr heading">Leave us a message</h4>
        <p><input id="nameBox" class="bar" onfocus="if(this.value == 'Name') { this.value = ''; }" onblur="if(this.value == '[[!+fi.contact_name]]') { this.value = 'Name'; }" type="text" name="s" value="Name" /> <input id="bnameBox" class="bar" onfocus="if(this.value == 'Business Name') { this.value = ''; }" onblur="if(this.value == '') { this.value = 'Business Name'; }" type="text" name="s" value="Business Name" /> <input id="EmailBox" class="bar" onfocus="if(this.value == 'Email') { this.value = ''; }" onblur="if(this.value == '') { this.value = 'Email'; }" type="text" name="s" value="Email" /> <input id="PhoneBox" class="bar" onfocus="if(this.value == 'Phone') { this.value = ''; }" onblur="if(this.value == '') { this.value = 'Phone'; }" type="text" name="s" value="Phone" /></p>
        <div class="clear"> </div>
        <p><textarea name="s" rows="5" cols="">Message

        you should put code tags arround your code!


        where are your tags for the form?
        <form> </form>

        [ed. note: Bruno17 last edited this post 14 years, 4 months ago.]
          -------------------------------

          you can buy me a beer, if you like MIGX

          http://webcmsolutions.de/migx.html

          Thanks!
          • 36969
          • 54 Posts
          <p>[[!FormIt? &hooks=`email` &emailTpl=`sentEmailTpl` &emailSubject=`Message From Contact Form` &emailTo=`[email protected]` ]]</p>
          <p>Please fill out the form below and submit to request more information.</p>
          <p> </p>
          <h4 class="colr heading">Leave us a message</h4>
          <p><input id="nameBox" class="bar" onfocus="if(this.value == 'Name') { this.value = ''; }" onblur="if(this.value == '[[!+fi.contact_name]]') { this.value = 'Name'; }" type="text" name="s" value="Name" /> <input id="bnameBox" class="bar" onfocus="if(this.value == 'Business Name') { this.value = ''; }" onblur="if(this.value == '') { this.value = 'Business Name'; }" type="text" name="s" value="Business Name" /> <input id="EmailBox" class="bar" onfocus="if(this.value == 'Email') { this.value = ''; }" onblur="if(this.value == '') { this.value = 'Email'; }" type="text" name="s" value="Email" /> <input id="PhoneBox" class="bar" onfocus="if(this.value == 'Phone') { this.value = ''; }" onblur="if(this.value == '') { this.value = 'Phone'; }" type="text" name="s" value="Phone" /></p>
          <div class="clear"> </div>
          <p><textarea name="s" rows="5" cols="">Message
          [ed. note: dgroppen last edited this post 14 years, 4 months ago.]
            • 36969
            • 54 Posts
            There were no "form" tags in the original html Bruno17. Like I said, it actually shows up and formats just fine on the published web page. My post above with the coding is in the content section of the resource page and the place holder is in my template between the div tags where this html originally was. It looks like 2 of my test emails came thru, but no content arrived with it, just a subject. I guess I am just a little confused on how to get this to work properly! Also, I was reviewing the tutorial on The Coding Pad web site for using FormIt and the html that she was working with for the form was substantially different from what I have in mine. I have no "action" call in my original html like she had in her template.
              • 3749
              • 24,544 Posts
              You definitely need form tags around the form.

              [[!FormIt ... ]]
              <form action="[[~[[*id]]]]">
              
                 (your code)
              
              </form>




              ------------------------------------------------------------------------------------------
              PLEASE, PLEASE specify the version of MODX you are using.
              MODX info for everyone: http://bobsguides.com/modx.html
                Did I help you? Buy me a beer
                Get my Book: MODX:The Official Guide
                MODX info for everyone: http://bobsguides.com/modx.html
                My MODX Extras
                Bob's Guides is now hosted at A2 MODX Hosting
                • 36969
                • 54 Posts
                Put the form tags in and so far it's a no go:

                <p>[[!FormIt? &hooks=`email` &emailTpl=`sentEmailTpl` &emailSubject=`Message From Contact Form` &emailTo=`[email protected]` ]]</p>
                <form action="[[~[[*7]]]]">
                <h4 class="colr heading">Leave us a message</h4>
                <p><input id="nameBox" class="bar" onfocus="if(this.value == 'Name') { this.value = ''; }" onblur="if(this.value == '') { this.value = 'Name'; }" type="text" name="s" value="Name" /> <input id="bnameBox" class="bar" onfocus="if(this.value == 'Business Name') { this.value = ''; }" onblur="if(this.value == '') { this.value = 'Business Name'; }" type="text" name="s" value="Business Name" /> <input id="EmailBox" class="bar" onfocus="if(this.value == 'Email') { this.value = ''; }" onblur="if(this.value == '') { this.value = 'Email'; }" type="text" name="s" value="Email" /> <input id="PhoneBox" class="bar" onfocus="if(this.value == 'Phone') { this.value = ''; }" onblur="if(this.value == '') { this.value = 'Phone'; }" type="text" name="s" value="Phone" /></p>
                <div class="clear"> </div>
                <p><textarea name="s" rows="5" cols="">Message</textarea></p>
                <div class="clear"> </div>
                <p><a class="buttonone" href="#">Submit</a></p>
                </form>
                  • 3749
                  • 24,544 Posts
                  The number 7 shouldn't be there. Paste my exact code for that line.
                    Did I help you? Buy me a beer
                    Get my Book: MODX:The Official Guide
                    MODX info for everyone: http://bobsguides.com/modx.html
                    My MODX Extras
                    Bob's Guides is now hosted at A2 MODX Hosting
                    • 36969
                    • 54 Posts
                    Just tried that BobRay, and no luck... sad
                      • 3749
                      • 24,544 Posts
                      What does your sentEmailTpl chunk look like?


                      ------------------------------------------------------------------------------------------
                      PLEASE, PLEASE specify the version of MODX you are using.
                      MODX info for everyone: http://bobsguides.com/modx.html
                        Did I help you? Buy me a beer
                        Get my Book: MODX:The Official Guide
                        MODX info for everyone: http://bobsguides.com/modx.html
                        My MODX Extras
                        Bob's Guides is now hosted at A2 MODX Hosting