We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 4602
    • 16 Posts
    is there any tutorial about using SpForm in Revo yet?
      • 28042 ☆ A M B ☆
      • 24,524 Posts
      I believe Bob’s Guides has one. http://bobsguides.com/spform-tutorial.html
        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
        • 20500
        • 9 Posts
        Hi there,

        I installed this through the manager in Revolution. Saved the [[!SPForm]] in one of my pages and the form shows up.
        But I can’t seem to find the contacts.cfg.php and spfconfig.cfg.php. Any idea?
          • 3749
          • 24,544 Posts
          In revolution, the snippet is controlled by its properties. If you edit the snippet and click on the "Properties" tab, you should see them. The safest way to use them is to override them with parameters in the snippets tag or create your own property set and specify it in the snippet tag like this:

          [[!SPForm@MyProperties]]


          That way, your changes won’t be overwritten if you upgrade the package.
            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
            • 21949
            • 7 Posts
            Nevermind.
              • 36519
              • 40 Posts
              Hello;

              I downloaded and tried to use the SPForm snippet (3.1.2 beta 1) with Revo and everything seemed to work except I did not receive any e-mail in my inbox.
              So I tried SMTP setting as suggested in the readme.
              now I am getting the following error


              Fatal error: Undefined class constant ’_MAIL_SMTP_PORT’ in /home/content/27/6158427/html/modx/core/components/spform/classes/spformprocclass.inc.php on line 591

              property settings (localSPFsetting) I modified from default values are;
              spfUsesSMTP "yes"
              spfSMTP_Host "myemailserver.net"
              spfSMTP_Username "name"
              spfSMTP_Password "password"

              there is one more spfSMTP setting "spfSMTP_Port 519" but this one is unclickable in the grid.

              the form resource page is simple one liner => [[!SPform@localSPFsetting]]

              Is there anything else I may be overlooking?
                • 3749
                • 24,544 Posts
                Try turning off all the SPForm SMTP settings and using the SMTP settings in System->System Settings. That way MODx will use SMTP for all email. If you use both sets of settings, the mailer gets confused.
                  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
                  • 10702
                  • 107 Posts
                  [solved: I made the changes in the file directly]

                  When I change in the lexicon the "enter-comments" nothing happens. Does anybody know how I can change the text above each filed?
                  For example "Please enter your comments below. Click "Submit" when done.:" into "Please enter your message"...

                  Hope anybody can help me smiley
                  Gerdi
                    • 36519
                    • 40 Posts
                    Hello, my problem turned out to be two issues, I believe

                    _MAIL_SMTP_PORT : I looked at the code and noticed all other variables in that section of codes started with MAIL_SMTP... No underscore at the start of variable name. So I removed the "_" and tried again.
                    This time, it showed the formatted error message saying the mail did not get sent.

                    I use GoDaddy server and thought this could be a host issue. I found the following info in Goddady’s page.

                    If you use the mail() function in your PHP, you do not need to specify an outgoing mail server. If you are using some other method besides mail() in your PHP code, use relay-hosting.secureserver.net for your relay server. This function is not supported on IIS 7

                    according to this article, php mail() should work, but somehow this simple php test code don’t send the mail.
                    <?php
                      mail("[email protected]", 
                      "test message from godaddy", 
                      "this is a test message, if you are reading this the email was sent successfully.");
                     ?>  


                    So I set the modx system setting to use SMTP with "relay-hosting.secureserver.net", no authentication, no username nor password, and voila, it worked. So now I have a form function on my site. laugh

                    I am still not sure why the mail() does’nt work. Maybe my plan does not include it huh but that’s another point. Good thing is, SPForm is working grin



                    PS. I refreshed Godaddy’s webformmailer installation and now mail() function is also working. Stange.
                      • 3749
                      • 24,544 Posts
                      Quote from: adachim at Sep 12, 2010, 09:41 AM

                      Hello, my problem turned out to be two issues, I believe

                      _MAIL_SMTP_PORT : I looked at the code and noticed all other variables in that section of codes started with MAIL_SMTP... No underscore at the start of variable name. So I removed the "_" and tried again.
                      This time, it showed the formatted error message saying the mail did not get sent.

                      Can you tell me what file (or snippet) you found that in?
                        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