On March 26, 2019 we launched new MODX Forums. Please join us at the new MODX Community Forums.
Subscribe: RSS
  • Hi all,

    I’m having a problem getting eForm verification to work. Although I enter the vericode correctly the form does NOT get sent. The error message I get is ’Invalid verification code’. I’m not sure whether it is from my server or from a bug in the eForm. I’m using a shared hosting server.

    I’m new to modx. I looked around for solution for this problem on the forum and google with no success. Please help if you can.

    Here is my code:

    The Call:
    [!eForm? &formid=`feedbackForm` &tpl=`master_contact_form` &report=`request_for_prop_report` &invalidClass = `invalidValue` &requiredClass = `requiredClass` &cssStyle = `form_error_style` &vericode=`1` &gotoid=`1` !]

    The form:

    <form id="feedbackForm" method="post" action="[~[*id*]~]">
    <input type="hidden" name="formid" value="feedbackForm" />
    <!-- formIdentifier document variable -->
    <!-- end formIdentifier document variable -->

    <input type="hidden" value="Pro" name="subject"/>
    <div style="margin-top: 44px;" class="name">
    <label for ="name">Name</label>
    <input class="input_txt" type="text" value="" name="name" eform ="Name:string:1"/>
    <!-- companyNameInput -->
    <div class="email">
    <label for="email">Email Address</label>
    <input class="input_txt" type="text" value="" name="email" eform="Email Address:email:1"/>
    <div class="name">
    <label for = "phone">Phone</label>
    <input class="input_txt" type="text" value="" name="phone" eform="Phone Number:integer:1">
    <!-- domainNameInput -->

    <div class="name">
    <label for = "message">Message</label>
    <textarea style="height: 120px;" name="message"
    eform="Message:string:1:please tell us how might be of help?:"> </textarea>

    <div class="captcha_container">
    <img alt="verification image" style="padding:4px; border:1px solid #5A5A5A;"
    src="[+verimageurl+]" id="captcha"/>
    <div class="message">
    <label for ="captcha_code"> Enter Above Characters </label>
    <input class="input_txt" type="text" name="captcha_code"/>
    <div class="clear submit_position clear_most">
    <input type="submit" class="button_primary" name="submit" type="submit" value="Submit" />
    • Is your form page set to uncachable?
      • I have the form page set to cacheable (cacheable checked on the settings page). I tried both i.e cacheable checked/unchecked, no difference at all.
        • Hello,

          I have exactly the same problem, but it works from times to times ... (actually, it’s works longer than it bugs)

          I get fed up with this pb so I unset the Captcha, because I don’t want my customers to be unable to reach me.
          If I have too many spams, I will reset it again.
          I hope it will be OK until I found a solution.


          Does any one have an idea about what’s happening ? It seams to be linked with the server ...

          note : I use MODx with infomaniak

          Thank you all

          • hmmmm... I’ve also started experiencing this problem on one of my modx sites.
            The page was set to cacheable so I turned it off, and cleared the cache.
            It now works for me fine - but my client is saying he still gets the ’invalid verification code’ error.
            I’ve asked him to clear his browser cache and he still gets it.

            I have turned it off for now...
            • I stopped using the default Captcha ages ago, in my opinion it doesn’t work as well as it should in comparison to the rest of the system.

              I would suggest using ReCaptcha and to help reduce more Spam use a small snippet that Susan Ottwell came up with:

              checkField from Susan

              ReCaptcha from Google

              Another thing - the eForm snippet that is currently distributed with MODx and the version that is in the repository are well out of date.

              I would advise on downloading the zip file attached to this post.