Data from conditional fields not submitting correctly.

  • dlopshire
  • Topic Author
  • Offline
  • Junior Boarder
  • Junior Boarder
  • Posts: 30
  • Thank you received: 0

dlopshire created the topic: Data from conditional fields not submitting correctly.

I have a form where the user submits basica contact information, then makes a choice from the drop down field. Based on the first choice, they choose from a second set of choices, then a third and fourth.

The form is displaying on the site perfectly. However, when the form is submitted, there are choices included that are not part of the presented choices.

Examples:
Success
Officials Name: John Doe
Association: ABC, ABCD
Post-Season Assignment Gender: Girls
Level: Girls 4A Sectional
Location: Darien (Hinsdale South)
Games: Game1, Game3
Partners Game 1: Tom Adams, Roger Klein
Partners Game 3: Juston White, Dale Clark

Fail:
Officials Name: Bill Jones
Association:
Post-Season Assignment Gender: Girls
Level: Girls 4A Regional
Location: Aurora (Illinois Math and Science Academy)Crete (Illinois Lutheran)Elgin (H.S.)
Games: Game2, Game4
Partners Game 2: Brian Zafar, Dan Useman

The location picks up several choices. When I check the form results in the dashboard, even though the user selected the correct Gender, Level and Site, it populates data in three location fields shown above.

I have checked all of the form data and it appears to be correct and consistent. What could be causing this?

Thanks
Dave
#233945
  • Posts: 2461
  • Karma: 86
  • Thank you received: 333

mihaela replied the topic: Data from conditional fields not submitting correctly.

Hello,

I assume what is causing you to receive the incorrect record of the submission.

Is the additional data that arrives data from hidden select lists (the ones that are not turned on based on previous selection)?

If that is the case, the problem is the way that you have defined list elements in your form.
By default, first option in select list is selected, even if that field remains hidden.
Therefore, to avoid submission of unwanted first options, instead of defining lists like this:
0;Title1;value1
0;Title2;value2
0;Title3;value3
you should define it the following way:
0;Select option;
0;Title1;value1
0;Title2;value2
0;Title3;value3

Let me know whether this is what was causing the issue.

Regards,

Mihaela
#233962
  • dlopshire
  • Topic Author
  • Offline
  • Junior Boarder
  • Junior Boarder
  • Posts: 30
  • Thank you received: 0

dlopshire replied the topic: Data from conditional fields not submitting correctly.

Here is an example of one of the "Select from List" fields:

0;Select Site;
0;Arlington Heights (St. Viator);Arlington Heights (St. Viator)
0;Aurora (Illinois Math and Science Academy);Aurora (Illinois Math and Science Academy)
0;Breese (Central);Breese (Central)
0;Chicago (Brooks);Chicago (Brooks)
0;Chicago (Clemente);Chicago (Clemente)
0;Chicago (King);Chicago (King)
0;Chicago (Little Village);Chicago (Little Village)
0;Chicago (Mt. Carmel);Chicago (Mt. Carmel)
0;Chicago (Payton);Chicago (Payton)
0;Chicago (South Shore International College Prep);Chicago (South Shore International College Prep)
0;Chicago (St. Patrick);Chicago (St. Patrick)
0;Clinton;Clinton
0;Dolton (Thornridge);Dolton (Thornridge)
0;East Peoria;East Peoria
0;Fairbury (Prairie Central);Fairbury (Prairie Central)
0;Freeburg;Freeburg
0;Freeport (H.S.);Freeport (H.S.)
0;Geneseo;Geneseo
0;Genoa (G.-Kingston);Genoa (G.-Kingston)
0;Jerseyville (Jersey);Jerseyville (Jersey)
0;Johnsburg;Johnsburg
0;Macomb;Macomb
0;Metropolis (Massac County);Metropolis (Massac County)
0;Mundelein (Carmel);Mundelein (Carmel)
0;New Lenox (Providence Catholic);New Lenox (Providence Catholic)
0;Norridge (Ridgewood);Norridge (Ridgewood)
0;Olney (Richland County);Olney (Richland County)
0;Rantoul;Rantoul
0;Salem;Salem
0;Sandwich;Sandwich
0;West Chicago (Wheaton Academy);West Chicago (Wheaton Academy)
0;Westchester (St. Joseph);Westchester (St. Joseph)

You can see the form live at chicagolandrefs.org/index.php/ihsa-playo...yoff-assignment-form

Any help would be great. It's driving me crazy having to contact most of the submitters for correct information.
#233982
  • Posts: 2461
  • Karma: 86
  • Thank you received: 333

mihaela replied the topic: Data from conditional fields not submitting correctly.

Hello again,

In that case, please explain once more what exactly is the problem.

Could the problem be that user selected one "Girls Class and Level", selected the location and afterwards, user changes his mind and selected another "Girls Class and Level" and therefore a new location?

In that case both locations would get saved.
This kind of behavior could be stopped by adding Actionscripts to empty certain elements on change.

Regards,

Mihaela
#233984
Moderators: ForumSupporttomeperica
Time to create page: 0.050 seconds

New Icon Packs Category!

Crosstec is now offering icon packs.

If you are a paying subscriber, icon packs are automatically added to your account.

Check out our icon packs page!

Live Support Chat Opened!

Join our Discord chat here to receive live support and talk directly to the team!

Summer Sale!

50% discount on all of our extension subscription plans, templates and icon packs!

Get Your Subscription Here

News and Updates

Get informed about new downloads, updates and more in our News and Updates newsletter.

All Extensions Subscription

Get 1 year access to all of our current and future products and 1 year of professional support -- 99 for just 49! (Summer Sale)

No support per domain or website installation limits! Includes all of our current and future Joomla!® extensions, Joomla!® templates for the duration of your membership. This means, by purchasing an All Extensions Subscription you'll have it all covered!

Get it from here

3rd Party Discount - 25% Off

We help you to keep your costs under control. If you are a new member and purchased a form building tool from a different form vendor, then you'll get a 25% discount on our subscription plans.

How to receive the discount:

Send us a quick email to sales@crosstec.org with a proof of purchase (for example a paypal receipt), await payment instructions and enjoy your membership!

Live Support Chat Opened!

Join our Discord chat here to receive live support and talk directly to the team!

Community Reward

Help us to create new extensions and plugins! With only $5 you help us a lot and get unlimited download access to all of our products, professional support and even more. Get your reward now!

Read More Here