Redirection in validation error...

Shows some Tutorials

Redirection in validation error...

Postby joayala on Thu Jan 10, 2008 3:16 pm

When I make a mistake in captcha image I get the message error and the form is shown in a new page... how can I get my form in the same position in my Joomla (between other mods)?

Thanks
Jos
joayala
Fresh Boarder
 
Posts: 18
Joined: Sun Dec 30, 2007 7:18 pm

Re:Redirection in validation error...

Postby GreyHead on Thu Jan 10, 2008 8:39 pm

Hi Jos,

I'm not sure that you can at the moment. The on-error routine just recalls the chrono-contact page.

I guess that the calling URL must be available somewhere and could be used to redirect - will have to dig into this a bit more.

Bob

PS Are you using the mambot to put the form in a content page or in a module?<br><br>Post edited by: GreyHead, at: 2008/01/10 15:40
Bob Janes
info at greyhead.net
ChronoForms Support If you like ChronoForms please vote or post a review at Joomla.org
User avatar
GreyHead
Platinum Boarder
 
Posts: 3176
Joined: Tue May 29, 2007 10:15 pm
Location: Brittany

Re:Redirection in validation error...

Postby joayala on Fri Jan 11, 2008 1:23 pm

Hi Bob,

Yes, I'm using the mambot to put my form in a module and of course it works perfectly.

Thanks for your time to resolve my question, I will be waiting for news.

Regards
Jos

PS. If you want to see my form I can send you the URL by email, this because it is not public yet.<br><br>Post edited by: joayala, at: 2008/01/11 08:25
joayala
Fresh Boarder
 
Posts: 18
Joined: Sun Dec 30, 2007 7:18 pm

Re:Redirection in validation error...

Postby GreyHead on Fri Jan 11, 2008 4:14 pm

Hi Jos,

Hmmm . . . not simple. At the moment, the mambot (and module) versions of a form just refer the results back to the ChronoForms component for processing. ChronoForms does not know where they are sent from and so just processes the results (including re-displaying the standard from page if there is a validation error).

I think - very much first thoughts - that it is possible to pass the referring page url back to ChronoForms so that if there is a validation error it will redirect to the calling page. But, I'm not sure that it's possible to safely pass back the $_POST variables used to fill the form fields with the submitter's data.

Perhaps if Max reads this he will hae some ideas.

Bob
Bob Janes
info at greyhead.net
ChronoForms Support If you like ChronoForms please vote or post a review at Joomla.org
User avatar
GreyHead
Platinum Boarder
 
Posts: 3176
Joined: Tue May 29, 2007 10:15 pm
Location: Brittany

Re:Redirection in validation error...

Postby petersen on Thu Mar 27, 2008 10:17 pm

Is there any progress on this? I'm anxious about deploying a form without any form of Image Validation.
petersen
Junior Boarder
 
Posts: 22
Joined: Thu Mar 27, 2008 3:10 pm

Re:Redirection in validation error...

Postby admin on Fri Mar 28, 2008 3:18 am

Hi Peterson, no not yet!
ChronoForms Developer Thanks for using ChronoForms.
If you have any problems with ChronoForms please tell us.
If you like ChronoForms please post a review at Joomla.org
Want users to submit their content to your website ? try Submit Story
Want to list/edit/delete your data ? try ChronoConnectivity
User avatar
admin
Platinum Boarder
 
Posts: 1956
Joined: Mon Aug 14, 2006 5:29 am

Re:Redirection in validation error...

Postby petersen on Fri Mar 28, 2008 3:50 pm

Fair enough. I guess I could deploy all of my page content within the form. Not semantically correct, but better than a shed load of spam.
petersen
Junior Boarder
 
Posts: 22
Joined: Thu Mar 27, 2008 3:10 pm

Re:Redirection in validation error...

Postby admin on Fri Mar 28, 2008 6:58 pm

Hi Peterson,

In chronocontact.php find those lines :

Code: Select all
showErrorMessage('Sorry, You have entered a wrong verification code');
         showform($_POST);


Change them to :
Code: Select all
echo "<script> alert('Sorry, You have entered a wrong verification code'); window.history.go(-1); </script>
";


This will fix it for you but forget about keeping data user added in the form! :)

Cheers

Max
ChronoForms Developer Thanks for using ChronoForms.
If you have any problems with ChronoForms please tell us.
If you like ChronoForms please post a review at Joomla.org
Want users to submit their content to your website ? try Submit Story
Want to list/edit/delete your data ? try ChronoConnectivity
User avatar
admin
Platinum Boarder
 
Posts: 1956
Joined: Mon Aug 14, 2006 5:29 am

Re:Redirection in validation error...

Postby petersen on Fri Mar 28, 2008 7:07 pm

For some reason, I don't keep form info if I get the validation image wrong on the component either.
petersen
Junior Boarder
 
Posts: 22
Joined: Thu Mar 27, 2008 3:10 pm

Re:Redirection in validation error...

Postby admin on Fri Mar 28, 2008 7:09 pm

K, this needs some preparations, if you don't care about it then do the hack above and it will fit your needs!!

Cheers

Max
ChronoForms Developer Thanks for using ChronoForms.
If you have any problems with ChronoForms please tell us.
If you like ChronoForms please post a review at Joomla.org
Want users to submit their content to your website ? try Submit Story
Want to list/edit/delete your data ? try ChronoConnectivity
User avatar
admin
Platinum Boarder
 
Posts: 1956
Joined: Mon Aug 14, 2006 5:29 am

Re:Redirection in validation error...

Postby petersen on Fri Mar 28, 2008 7:11 pm

Thanks. I'm still working out if this will be suitable for my needs.
petersen
Junior Boarder
 
Posts: 22
Joined: Thu Mar 27, 2008 3:10 pm

Re:Redirection in validation error...

Postby GreyHead on Fri Mar 28, 2008 7:14 pm

Hi Petersen,

Sometimes it's simpler to copy the content page html into ChronoForms rather than try to use the mambot in a content page.

Bob
Bob Janes
info at greyhead.net
ChronoForms Support If you like ChronoForms please vote or post a review at Joomla.org
User avatar
GreyHead
Platinum Boarder
 
Posts: 3176
Joined: Tue May 29, 2007 10:15 pm
Location: Brittany

Re:Redirection in validation error...

Postby petersen on Fri Mar 28, 2008 7:19 pm

That's what I've done. :)
petersen
Junior Boarder
 
Posts: 22
Joined: Thu Mar 27, 2008 3:10 pm


Return to How To

Who is online

Users browsing this forum: No registered users and 2 guests