after the submit action?
In my form, on submit, I save datas into database and redirect the user to the page where he come from before the Form.
I would like to display temporary a message as: "Thank you for registration, you will receive a confirming e-mail" and then redirect (after 5 sec.) to another page.
Thanks to help me.
Jérôme
Hi Fredrik
I put this code in 'Form Code'-->'onSubmit Events Code'-->'On Submit code - after sending email'
as you told me... but it's do anything!
Do I made a mistake on the place to put this code?
Or I have to active something else?
Regards
Jérôme
Hi Jerome,
Actually, I managed to screw up with that code. There's a single ' missing at the end of the first argument for setTimeout(), I'll update my initial post in a moment..
/Fredrik
G'day Jerome,
Any valid URL should do. Keep in mind that a valid URL must also contain a protocol specifier, that's why we start it with 'http://'.
I did a test-submission, and it would appear the JS-code was not included in the page at all, which I find puzzling. I did however, end up on an article-page. Could you check that the "General->Form URLs->REdirect URL" setting is empty?
/Fredrik
Hi
in the "General->Form URLs->REdirect URL", i had set the redirect url "http://www.jum31.fr/test/index.php?option=com_content&view=article&id=56&Itemid=65" because i would like to return to this page after the display of the "validation message". Maybe i misunderstood what your code make.
So I set nothing in the "General->Form URLs->REdirect URL" and then i put the "http://www.jum31.fr/test/index.php?option=com_content&view=article&id=56&Itemid=65" url in your code and now, at the submission, i have for 5 sec. the page "http://www.jum31.fr/test/index.php?option=com_chronocontact&chronoformname=Inscription_BAK" without the form (none information) and then i am redirect to the article from which i came.
this working seems fine but i would like to had a message like "thank you to register to this conf." on the 5 sec. displayed page.
i'm not sure to be clear when i read what i write above
Jérôme
Yessssss !!!!!!!!!
Great, the message is well displayed.
thank you very much for all.
I have 1 or 2 others questions, if i would dare...
I dare :mrgreen:
In this form, there is no control on existing e-mail, so, if a person register again with the same e-mail, there is no error message. Do i have to pass by a javascript or php script?
The second problem is that i would like to have a dynamic form:
"Depart. adhésion" and "Num adhérent" fields would be displayed only when "Adhérent Jumeaux et Plus" item is selected in "Qualité" choice.
Jérôme
That's work well, good.
I think it is normal that the form is cleared after the error message and all informations have to been typed again?
No idea for the dynamic form?
Promise, it's the last question 😶
Hi Jérôme,
In the Form General Tab set "Republish fields if error occured" to 'Tryto Republish'
Bob
Thanks GreyHead and Fredrik
I'll test that toonight and then publish my site.
Your help was greatfull
Hope to discuss with you for another think than problem...
Jerome
bad news😢
The javascript code don't work. I put it in the 'Form Code'-->'Main OnLoad/View Code'-->'Form Javascript' box as you said!
the link is the same if you want to play with the form
Jérôme
Sorry, my bad.
'hide' should really be 'hidden' in that script.
/Fredrik
That's better🙂
is-it possible to make textbox hidden at the start of the form?
The default choice is 'Selectionner' and not 'Adhérent Jumeaux et Plus' so, the textbox are visible until i select a quality
I'm installing the final site so i'll test this last code after.
Again, thanks a lot for your help
Jérôme
After some instal and some test, all is OK.
Again thanks to you
Jérôme