Conditional fields and values

18 years 3 months ago #3568 by mikko
Replied by mikko on topic Re:Conditional fields and values
Sounds correct to me. Can you give the URL of the site so that I can test it to see wether it is a browser issue or not.

The condtions apply to only fields that are on tabs which are before the tab created by the plugin. This is a due to a bug in CB. (the bug is a one liner and will be fixed in next release)

mikko

Please Log in to join the conversation.

18 years 3 months ago #3674 by gaz36f
Replied by gaz36f on topic Re:Conditional fields and values
Thanks Mikko; actually it was my mistake. I had the condition actually within the conditions tab and since moving it to an earlier tab it works a treat. Thanks very much for a wonderful plugin.

Can I ask?; I know the condition is restricted to one field or value but I want to create a condition when there is a particular value chosen, two further fields will show.

For instance, if field1 has two values (values1 and values2) and I want two new fields to show (fields2 and fields3) if value1 is chosen or not at all if value2 is chosen, is this possible?

Also, is there anyway of hiding the conditions tab please?

Thanks and best wishes,

Gary

Please Log in to join the conversation.

18 years 3 months ago #3698 by mikko
Replied by mikko on topic Re:Conditional fields and values
You can specify the same condition ID for several fields or values. So it is possible to do what you describe.

The extra tab is needed because of a bug in CB core. When the team fixes this, I will update the plugin so that the tab si not needed anymore.

mikko

Please Log in to join the conversation.

18 years 2 months ago #4575 by stephen
Replied by stephen on topic Re:Conditional fields and values
Hi there,
this seems like a great plug in. I can't seem to get it to work though.
I have an option for a field during registration with 'yes' or 'no', and if the user selects the yes radio button I would like other fields to become visible.
I created the conditions row with
id: 12
fieldname: cb_groupleader
value: Yes
I then changed the conditionsID in each field to 12, but they all are visible despite which option is selected.
Does the field cb_groupleader need to be on the conditions tab or on another tab? Also, do the fields dependent on the condtion need to be on the same tab? Thank you so much for any help and for your hard work on this!

Please Log in to join the conversation.

18 years 2 months ago #4592 by mikko
Replied by mikko on topic Re:Conditional fields and values
There is a bug in CB plugin framework that forces to use the conditions tab. After the next release this will be corrected and I will update the plugins so that you do not need the conditions tab any more.

The conditions plugin works by inserting javascript to the form. This javascript is used to hide the fields that are not supposed to show. Currently javascript can be included only in the header of the tab, i.e. before the fields. Since JS is executed as loaded, it applies to fields that were loaded before the JS, meaning that only the fields that are _before_ the conditions tab can have conditions.

After next release of cb it is a minor change to make it work better.

mikko

Please Log in to join the conversation.

18 years 2 months ago #4755 by Dehaw
Replied by Dehaw on topic Re:Conditional fields and values
Hi Mikko,

Firstly, thanks for a great component or the thought of it is good anyway.

I just cannot get this working, at all?

I have followed the instructions word for word and it just doesn't work, does it support the registration process?

I am trying to hid about 15 fields so that if the person selects yes they wish to fill in more details then it will show the other fields but they seem to show irrespective.

Please help.

The url is www.servicesuneed.com

Derek

Please Log in to join the conversation.

Moderators: beatnantkrileon
Time to create page: 0.229 seconds

Facebook Twitter LinkedIn