I have a form broken down into 4 <fieldset> setup as an accordion. Each panel of the accordion has a button which is 'Proceed to next step'. I'm using Chronoforms validation and would like to validate each fieldset when I click the button. Is it possible to call the validation for a set of fields not the entire form?
Thanks
Pete
Hi Pete,
That's not easy, you may make it a multi page form, that would validate each page before going to the next one.
Other users may have posted solutions for this in the past, so you may also search the forums!
Regards,
Max
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
If I put the validation of each fieldset to one side, I've found http://www.chronoengine.com/faqs/58-cfv4/cfv4-elements-and-html/2660-how-can-i-build-a-tabbed-form.html
which gives me a good starting point and the demo at http://greyhead.org/index.php?option=com_chronoforms&tmpl=component&chronoform=demo_form_sliders does what I want. The problem I have is that I've custom built my form rather than using the Wizard.
As a result, my validation call in the head references FormCheckMax, rather than FormCheckJPane. How do I get it to switch when using a custom form?
Looks like I need to add
<?php jimport("joomla.html.html.tabs");?>
to the top of my form code. Which is a little silly as it's already working but no biggie.
The problem I have now is that when I submit the form and the validation runs, it opens the correct panel (that has the incorrect field) but the panel is blank (actually opacity: 0).
Any ideas?
Please upgrade to the latest v4 for Joomla 3, it had a fix for the tabs, just install it OVER yours!
Regards,
Max
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
Further to this, if I add <?php jimport("joomla.html.html.slider");?> to the top of my form HTML, it loads the formcheck-jpane but I revert back to the blank accordion slide when I validate.
Hi petersen,
Of course, the js code was modified to find the fields under specific containers created by the wizard, if you have your own markup structure then the code will need to be modified, I suggest that you add the same containers classes to your custom html.
Regards,
Max
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
I see that the wizard applies unique ids to each element. Will I need that or just the wrapping containers?
Maybe just the containers in order to get the selectors in the validation file to work correctly, because if the container's element is not found by the selector then the code fails!
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
That code may not be enough, you will have to display the tab's body, and hide the other one which is not active, and do the same for the tabs titles.
I suggest that you simply give your tabs containers the same classes as in the validation js code, or use your form code into custom code elements and place them inside Chronoforms normal tabs using containers, you can then style the generated tabs if you like!
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
Makes sense. Thanks for your help on this.
Out of interest, do you know of a way to add a button to each panel to switch to the next panel?
Please check this FAQ:
http://www.chronoengine.com/faqs/58-cfv4/cfv4-elements-and-html/2660-how-can-i-build-a-tabbed-form.html
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
That works for the tabbed version but not the slider?
I think so yes, its a custom code, and is used mainly for tabs, changing it to work for sliders will require writing new code and testing it.
Regards,
Max
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.