Forums

Expanding Form?

Hammerhead 01 Dec, 2009
I seem to recall this being discussed before, but I guess I'm just not using the right search terms.

The form I'm working on is fairly long (about 50+ fields) and I would like to know if there's a way for some options to be hidden because they won't apply to everyone. I want those last options to expand and be revealed only when a "are you interested in...?" radio button is clicked. If 'no' is selected the form does not expand, but if 'yes' is selected, the 20 questions are shown.

I'm pretty sure we do not want a multi-part presentation because as I understand the operation of it, that forces customers who are not interested in those options to have to look through the questions anyway.

Can someone point me in the right direction?

Thanks!
Max_admin 01 Dec, 2009
Hi Hammerhead,

This will require that you add those stealth 20 questions inside a "div" with style="display:none", by default they will be hidden, but add onClick event for your "yes" radio box to toggle the style of the div to display:block

Regards
Max
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
Hammerhead 01 Dec, 2009
Max, thanks again for your help but I'm totally lost. It'd be great if chronoforms had this built in as an item in the toolbox so dummies like me can drag and drop - just to give you an idea of what you're dealing with, here.😶

Can you be more explicit?
Hammerhead 03 Dec, 2009
Max, though I would still like to understand how to use the div statements (because I'm a dolt where programming is concerned), but I had another thought to get this to work for me.

Can I create a multipart form with required answers on both forms linked together under a mother, but where the first form can be submitted independently (despite the required answers on the 2nd form) for those who only desire to answer questions related to the first segment? If so, how does the email response work?

Wow. I just read what I wrote above, and my head exploded. :mrgreen:
Max_admin 05 Dec, 2009
Hi Hammerhead,

It's easy to make these custom ideas with the wizard, may be, but not with the current wizard version, maybe the next one!

I think the the way I suggested is better and less complicated than your idea which I could not understand!😀

It's not hard at all to do it, please google and read about div tags in HTML, style attributes and onClick event, it should take you less than 10 minutes to understand every one of them, then you can do it the way I suggested in about 10 minutes more!🙂

Let me know how you proceed!

Regards,
Max
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
Hammerhead 05 Dec, 2009
Max, thanks again for your reply.

I decided the <div> method won't work, because of how the questionnaire is structured.

What I think I need here is a multi-part form.

Can I create a multipart form with required answers on both forms linked together under a mother, but where the first form can be submitted independently despite the required answers on the 2nd form? If so, how does the email response work?

IOW, the 2nd section has required responses, but only for those persons to whom they apply. I need to know if two forms can be linked together, but still operate and be submitted independently?

For example:
Form 1 has required questions and a 'submit' button
Form 2 has required questions and a 'submit' button
If user does not have interest in questions on form 2, can he still submit the first for (without proceeding to the 2nd form) even though there are required answers on the 2nd form?
Max_admin 06 Dec, 2009
Hi Hammerhead,

I don't know why you excluded the div solution, but the answer to your question is yes, its possible, in the multi page plugin config there is a parameter for "end button name" or something like that, so, add to submit buttons to your first form, give one the name="next" and give the 2nd the name="finish" and set the "end button name" option (or whatever its called) to "finish" (no quotes)

now, if user click "next" then they should go to the 2nd form, but if they click "finish" then the process should be terminated and on submit tasks in both the 1st form and mother form should run!

Regards
Max
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
Hammerhead 06 Dec, 2009

I don't know why you excluded the div solution...


Because the questions in the 2nd section don't apply to all customers, but if they're on the same page, all customers will still be forced to complete them presenting an inconvenience and possible confusion.

IOW, all questions in the 1st section apply to all customers, but only some customers will need to answer questions in the 2nd section. I don't want to force everyone to answer all questions.

And besides, I'm still not understanding how to use the div tags anyway. :mrgreen:
This topic is locked and no more replies can be posted.