Skip to Content Skip to Menu

🎃 Happy Halloween! Treat yourself with an awesome discount on memberships! Get 20% off now with code SPOOKY-2024!

CB Conditional Fields

  • who_else
  • who_else
  • OFFLINE
  • Posts: 61
  • Thanks: 2
  • Karma: 1
11 years 2 months ago #232562 by who_else
CB Conditional Fields was created by who_else
I'd like to achieve the following:

Offer a profile field with some multiselectable values.
If i select one or more values, there will be several checkboxfields available, on the same page.

Can i do it with Conditional fields (3.0)?

Thanks for pointing me in the right direction.
Best

Please Log in or Create an account to join the conversation.

11 years 2 months ago #232596 by LearnThingsAfrica
Replied by LearnThingsAfrica on topic CB Conditional Fields
Short answer -> Yes!

Please Log in or Create an account to join the conversation.

  • krileon
  • krileon
  • ONLINE
  • Posts: 48466
  • Thanks: 8280
  • Karma: 1443
11 years 2 months ago #232630 by krileon
Replied by krileon on topic CB Conditional Fields
Yes, please see the below tutorial to get you started with using CB Conditional.

www.joomlapolis.com/support/tutorials/107-use-cases/18336-using-cb-conditionals-to-hide-or-show-fields-or-tabs


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

Please Log in or Create an account to join the conversation.

  • who_else
  • who_else
  • OFFLINE
  • Posts: 61
  • Thanks: 2
  • Karma: 1
11 years 2 months ago #232761 by who_else
Replied by who_else on topic CB Conditional Fields
Well, i decided to solve it that way:

Create two conditional fields, with each two conditions (self), so they will only show on a specific Tab, if it meets one of two criterias.

This seems to work.

The tab, on the other hand also should show only on two specific usergroups out of five.

So if you belong to Usergroup A (condition 1) you will see that tab and if you belong to Usergroup B (condition 2) you will see that tab as well.
Currently it only shows the Tab on condition 2, ignoring condition 1. The settings are the same, besides the Usergroup, of course. If i set condition 1 to CB Configuration and add the Usergroup A as condition 3, it will only show on Usergroup A and not in Usergroup B.

This is very confusing. Any idea? I could create a second Tab, but would have to create the fields a second time and linkt it to the second Tab, since a CB Field can only be attached to one Tab, not to two.

Thanks for help.

Please Log in or Create an account to join the conversation.

  • krileon
  • krileon
  • ONLINE
  • Posts: 48466
  • Thanks: 8280
  • Karma: 1443
11 years 2 months ago #232781 by krileon
Replied by krileon on topic CB Conditional Fields
You can't condition self multiple times when using two-way conditionals. Conditions are not AND or OR scenarios. They're completely independent of one another. In other words the last condition executed on a tab or field is the one that will control its display. If you need to check the same field for 2 different values then use REGEX operator with for example /Value1|Value2/ to match 2 values.


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

Please Log in or Create an account to join the conversation.

  • who_else
  • who_else
  • OFFLINE
  • Posts: 61
  • Thanks: 2
  • Karma: 1
11 years 2 months ago - 11 years 2 months ago #232830 by who_else
Replied by who_else on topic CB Conditional Fields
Well, renamed the both usergroups, so they share some parts of the name, so i was able to use the "contain" expression and now it works. It didn't work with the REGEX Approach, that did strange things: Shown all other tabs, even that ones, who weren't for the user profile. But the tabs didn't contain any data, so i tried it with different operators.

Just if anyone runs into the same situation ;-)
Last edit: 11 years 2 months ago by who_else.

Please Log in or Create an account to join the conversation.

Moderators: beatnantkrileon
Powered by Kunena Forum