I was wondering if there was a way to do this on a site running Chronocontact v3.2 and Joomla 1.5.x
Basically we have a long contact form with many fields, and if the user messes up the CAPTCHA, the page reloads with none of their data present.
The site is running on HTML4, so I can't utilize HTML5's web-storage system like I have seen suggested on a few development community sites (I tried using Garlic.JS with no success.)
Sorry if there's an obvious solution to this, but I've spent the last few days searching both this forum and on Google for an answer.
Hi thedan1984,
The data should republish automatically - provided that the Republish option in the Show HTML action is set to Yes (which is is by default). Are you doing any other processing when there is a Captcha error apart from using an Event Loop action to re-load the form?
Bob
Thanks for the answer. For whatever reason though, this was not on my default. I've been using this version of Chronocontact and it doesn't appear to be on by default for any of them (a bug maybe?) - Your solution worked though, thanks!
I did notice one thing, the email field got repopulated with:
<script language='JavaScript' type='text/javascript'> <!-- var prefix = 'mailto:'; var suffix = ''; var attribs = ''; var path = 'hr' + 'ef' + '='; var addy71572 = 'EMAILTEST' + '@'; addy71572 = addy71572 + 'gmail' + '.' + 'com'; document.write( '<a ' + path + '\'' + prefix + addy71572 + suffix + '\'' + attribs + '>' ); document.write( addy71572 ); document.write( '<\/a>' ); //--> </script><script language='JavaScript' type='text/javascript'> <!-- document.write( '<span style=\'display: none;\'>' ); //--> </script>This e-mail address is being protected from spambots. You need JavaScript enabled to view it <script language='JavaScript' type='text/javascript'> <!-- document.write( '</' ); document.write( 'span>' ); //--> </script>
Anyway to disable this part from within Chronocontact?
Hi thedan1984,,
Sorry, I'm having a slow day today. The Republish was off by default in CFv3 and is on by default in CFv4.
The JavaScript is from the Joomla! Email Cloaking Plug-in which is enabled and is trying to cloak the sample e-mail in the ChronoForms validation message. Disable the plug-in temporarily to check this is the problem. If you need the plug-in change the plug-ins order so that Email Cloaking runs before ChronoForms.
NB These are Joomla! plug-ins that you manage from Site Admin | Extensions | Plug-in Manager
Bob
Thanks Bob. That worked perfectly. Thanks a lot for the speedy replies! 😀