We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 34162
    • 1 Posts
    Hopefully I’m not sounding dumb here, I’m no programmer, but a designer who is trying to offer CMS to those clients who cannot afford a bespoke one. Will this Snippet allow a client to update a section of a page, say a fiddly table of data or an image gallery via a form rather than going via the manager? That would be awesome if so..

    Jason
      • 22427
      • 793 Posts
      @markg:
      Where’s the validation message and how do I change it.
      Have a look at the language file assets/snippets/eform/lang/english.inc (or whatever other language you need).
        • 18367
        • 834 Posts
        Quote
        Where’s the validation message and how do I change it.
        Have a look at the language file assets/snippets/eform/lang/english.inc (or whatever other language you need).

        Thanks
          Content Creator and Copywriter
          • 18367
          • 834 Posts
          OK, Next question

          I can see how i could change the actual message in
          $_lang["ef_thankyou_message"] = "<h3>Thank You!</h3><p>Your information was successfully submitted.</p>";


          But what if I wanted to have an alternate validation message?

          EG I have about half a dozen different forms on the site and I may need a distinct Thank you for the different forms.

          How would I do that?

          Thanks
            Content Creator and Copywriter
            • 3749
            • 24,544 Posts
            I’m not an eForm expert, but I think you can have a separate "thank you" page for each form and use eForm’s &gotoid=`n` where n is the id of the thank you page.
              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
              • 18367
              • 834 Posts
              Hey Bob, thanks

              but for the non-coder like me

              where exactly is the &gotoid=`n`

              I’ve looked in the chunk, the snippet and the inc file and I can’t see it.

              Do I have to add it to one of these? If so which one and where?

              grin
                Content Creator and Copywriter
                • 28042 ☆ A M B ☆
                • 24,524 Posts
                Those parameters (&gotoid=`n`) are put in the snippet tag. Note that those are `` backticks, not ’’ single quotes. Also, make sure your snippet has the correct form, like [[snippetName? &param1=`value1` &param2=`value2`]] and it’s all on one line (a really long one might be shown on multiple lines in your editor, but there aren’t any explicit line breaks in it).

                These get converted to basic PHP variable declarations ($gotoid = ’n’; ) as the snippet is run.
                  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
                  • 22427
                  • 793 Posts
                  The "ef_thankyou_message" is only displayed in the absence of both the &gotoid parameter and the &thankyou parameter in the snippet call. So using one of these parameter gives much more flexibility.
                    • 21395
                    • 91 Posts
                    Quote from: sarah at Mar 09, 2008, 06:11 PM


                    Fatal error: Call to undefined function: eform2db() in E:\hshome\arterial\arterial.com.au\microsite\assets\snippets\eform\eform.inc.php on line 386

                    Sarah

                    Same message for me, and I found the problem. I had tested the 50-field form with just three fields being moved to the database, so I knew the script worked. When I put in all 50 fields I got the wobble. It had to be some limitation on array size, or poor data. I eventually tracked down three errors is defining the $dbTable[Fieldname] array. Once they all matched the MySQL field names the message stopped. Poor data and a message that doesn’t exactly point the programmer in the right direction.
                      MODX Revolution 2.6.5-pl (traditional)

                      Hosted on MODX Cloud

                      Skype: nicbaldeagle
                      • 10226
                      • 412 Posts
                      what needs to be modified to use a different db on the same server with the same permissions?