We use cookies to improve your experience. No personal information is gathered and we don't serve ads. Cookies Policy.

ExpressionEngine Logo ExpressionEngine
Features Pricing Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University
Log In or Sign Up
Log In Sign Up
ExpressionEngine Logo
Features Pro new Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University Blog
  • Home
  • Forums

Conditional Field is showing the wrong options in the field it is referencing

How Do I?

freaksarise's avatar
freaksarise
11 posts
3 years ago
freaksarise's avatar freaksarise

Hi. I am inside of a field set. I have a grid that I am attempting to make conditional so that it displays when a separate pulldown selector field equals one of its values. For example, the pulldown has the values cat, dog, or mouse. If mouse, I want the grid to display. However when I am building the condition using the tools provided under the “make conditional” option, the values it serves for the field I choose are not cat, dog, mouse. They are pizza, bread, tea (which is a totally different field’s values). I never swapped the fields or renamed them. I also cleared cache and reindexed. Is this a bug? Thanks

EE Version 6.3.4

       
Andy McCormick's avatar
Andy McCormick
322 posts
3 years ago
Andy McCormick's avatar Andy McCormick

I haven’t seen this before. Do any of your fields contain the values you’re seeing?

       
Andrew Gunstone's avatar
Andrew Gunstone
102 posts
3 years ago
Andrew Gunstone's avatar Andrew Gunstone

Hey Andy. I’ve seen this before in one of my EE6.3.4 sites. To replicate, you need to create 3 fields (all native). First, create a select dropdown list called “food”, and add in some options (pizza, burger, sandwich). Then create a second select dropdown list called “animals”, and add in some options (cat, dog, mouse).

Finally create a text field called “Favourite Burger Restaurant”. Our plan is to make this field conditional on the ‘food’ field having ‘burger’ selected.

So … select to make this text field conditional … and choose the FIRST select list you created (‘food’) … the options that are presented will be for the SECOND select list (cat, dog, mouse), and not the ‘food’ list as expected.

Basically what I was finding was that no matter which select dropdown field I selected, it only showed the options for the most recently created select dropdown field.

I’ve not tested this on EE6.3.5 or EE7.

       
oinkanalyst's avatar
oinkanalyst
2 posts
2 years ago
oinkanalyst's avatar oinkanalyst

According to what you have stated, the first thing that you need to do is determine whether or not the user is logged in, and if they are, you should modify the content that they view in some way based on this information (for example, by redirecting the user to a second template that can verify that they are logged in). You inquired about the redirection, but you did not specify how you would go about actually confirming again.

In the event that what you are truly interested in learning is how to perform the reconfirming, the final goal is to persuade them to log in once more; the question that remains is how to do it.

Therefore, regardless of how you go about doing it, what you need to do is log them out and then use a form that redirects them to wherever you want them to go in order to get them to log back in again.

If you are working through an add-on, then doing this is not a complex process basket random, which is a TFA add-on for EE6).

       

Reply

Sign In To Reply

ExpressionEngine Home Features Pro Contact Version Support
Learn Docs University Forums
Resources Support Add-Ons Partners Blog
Privacy Terms Trademark Use License

Packet Tide owns and develops ExpressionEngine. © Packet Tide, All Rights Reserved.