We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 17301
    • 932 Posts
    Hello,

    I have a website using the migxMultiLang and I've been ripping my hair out trying to get the contact forms to work which is odd considering i've built literally hundreds of sites in MODX using formit.

    For some reason the contact forms just weren't working and no error was being shown in the error log and nothing was being returned by formits error's either. I stripped out the validation, the spam check and put everything to basics with still no luck.

    Finally I found that the issue was that my formit was in my sites template and my template was in a chunk because migxMultiLang requires it to be. I copied everything from the chunk and pasted it into a blank resource and it worked fine.

    Not sure if anyone has come across this issue before?

    Best,

    This question has been answered by lkfranklin. See the first response.

      ■ email: [email protected] | ■ website: https://alienbuild.uk

      The greatest compliment you can give back to us, is to spend a few seconds leaving a rating at our trustpilot: https://uk.trustpilot.com/review/alienbuild.uk about the service we provided. We always drop mention of services offered by businesses we've worked with in the past to those of interest.
    • discuss.answer
      • 17301
      • 932 Posts
      Ok just to update after a bit of research I found the solution (provided by Bruno a few years ago).

      You need to double cache your calls ie:

             [![!FormIt? 
      			&hooks=`spam, email, redirect` 
      			&emailTpl=`myEmailChunk` 
      			&emailTo=`***`
      			&redirectTo=`8` 
      			&emailSubject=`Notify me when *** is available!` 
      			&submitVar=`submit` 
      	              ]]
      
      			<form action="[[~[[*id]]]]" method="post">
      				<input name="nospam:blank" type="hidden" value="[![!+fi.nospam]]" />
      				<input type="text" id="name" name="name" placeholder="Your Name" value="[![!+fi.name]]">
      				<input type="text" id="email" name="email" placeholder="Your Email" value="[![!+fi.email]]">
      				<input type="submit" id="submit" name="submit" class="button price" value="Send">
      			</form>
        ■ email: [email protected] | ■ website: https://alienbuild.uk

        The greatest compliment you can give back to us, is to spend a few seconds leaving a rating at our trustpilot: https://uk.trustpilot.com/review/alienbuild.uk about the service we provided. We always drop mention of services offered by businesses we've worked with in the past to those of interest.
        • 4172
        • 5,888 Posts
        yeah, since every output is cached for each language, you need do mask everything, which is dynamic at each request or disable the caching of the main-snippet-call in the template.
          -------------------------------

          you can buy me a beer, if you like MIGX

          http://webcmsolutions.de/migx.html

          Thanks!