Hide/Show fields based on a field selection

be berlin80210 02 Feb, 2010
Hi Chrono-formers!

I've searched the boards for solutions for this, but am encountering obstacles.

What I need is a form that based on the selection from a drop down field, the user can dictate how many fields to be displayed:

example:

Number of Entries {choose a number}
{1}
{2}
{3}
{4}
{5}
{6}
{7}
{8}
{9}
{10}

Based on the selection above a corresponding number of fields would display for the user to fill out.

I found a thread in the forum with a link to this solution:
http://www.quirksmode.org/dom/domform.html however, it doesn't work when I implement it in the form.

I am open to alternative solutions, but need to get this form up and running! I am also open to implementing a button that will allow the user to add additional entries (as seen here: http://functionstaffing.com/index.php?option=com_chronocontact&chronoformname=TheAGame2010

Thanks for your help!!!
Gr GreyHead 03 Feb, 2010
Hi berlin80210,

From memory you can adapt the quirksmode code to work with ChronoForms though there are some problems with validation. I thought that someone posted a 'how-to' thread on this a few weeks ago.

Bob
Gr GreyHead 03 Feb, 2010
Hi berlin80210,

You are right - most scripts won't work out of the box. That's why I said that you can *adapt* it to work.

Bob
be berlin80210 03 Feb, 2010
Could you be specific as far as *adapt*ing this script for use with Chrono Forms? I have some basic knowledge of JS and PHP, but this is a bit over my head.
Gr GreyHead 03 Feb, 2010
Hi berlin80210,

Sorry, I just don't have time at the moment to do custom script adaptation here. But I think that if you search the forums for Quirksmode you will find that someone has already done it.

Bob
This topic is locked and no more replies can be posted.