Home › Toolset Professional Support › [Resolved] Checkboxes maximum options?
This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.
Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.
No supporters are available to work today on Toolset forum. Feel free to create tickets and we will handle it as soon as we are online. Thank you for your understanding.
Sun | Mon | Tue | Wed | Thu | Fri | Sat |
---|---|---|---|---|---|---|
- | 7:00 – 14:00 | 7:00 – 14:00 | 7:00 – 14:00 | 7:00 – 14:00 | 7:00 – 14:00 | - |
- | 15:00 – 16:00 | 15:00 – 16:00 | 15:00 – 16:00 | 15:00 – 16:00 | 15:00 – 16:00 | - |
Supporter timezone: Europe/London (GMT+00:00)
Tagged: Setting up custom types, Types plugin
Related documentation:
This topic contains 17 replies, has 3 voices.
Last updated by fedeD-3 6 years, 5 months ago.
Assisted by: Nigel.
Hi, is there a maximum number of options that I can create with checkboxes field type?
I need to create 841 options, is it possible?
Languages: English (English ) Spanish (Español )
Timezone: Europe/London (GMT+00:00)
Hi there
My main concern in that case would server resources, but I don't want to encourage you to go ahead because setting up 841 checkbox options will itself be very time consuming and I would hate for you to get to 600 and then find you cannot add more.
I've put a question in to the developers to get confirmation if there is a specific limit beyond the server resources and I will update you. That might not be until tomorrow morning.
Thank you Nigel, I've decided to use taxonomies, but I have some questions.
This is what I want to create.
I need to create a business directory where every company have the opportunity to select from 1 to 841 parent-categories. (I've fixed this problem using taxonomies).
And for every parent-category the company have the opportunity to select from 1 to 30 child-categories. I'd like to use taxonomies, but I've seen that is not possible to create two different dropdown filters for parents and child taxonomies.
Instead of using child-directories, I'd like to create 841 (one for every parent-directory) checkboxes, everyone with 30 options.
So I would like to create two levels of search:
1. a first search page, where users can select one of the 841 parent-categories from a dropdown (they also can filter region and state)
2. a second search page (one for every parent-category) where users can select one of the 30 options of the parent-category (and also here they can filter region and state).
Here are my questions:
- Is it possible to create 841 checkboxes everyone with 30 options?
- Is it possible to create automatically the 25.230 options (841 checkboxes * 30 options)? For example with wp-all-import?
Languages: English (English ) Spanish (Español )
Timezone: Europe/London (GMT+00:00)
That is a *lot* of options 🙂
Can you give me a few concrete examples to help me think about this and give you a more informed opinion about how to set it up?
What would a couple of the parent terms be, and what kind of child terms (options) would each of these have?
Each would have 30 unique options, or all 841 parent terms would have the same possible 30 options to choose from?
The parent terms are like these: 01.01.01 - 05.01.09 - 10.08.10 - 20.04.39
The 841 parent terms have the same 30 options (From R1 to R15 and from D1 to D15).
This is an example of the first level of search:
A user needs to know which companies in Italy have the parent term 10.08.10.
So from a dropdown it selects Italy and then, from another dropdown, it selects the parent term 10.08.10.
This is an example of the second level of search:
A user need to know which companies in Italy have the option R5 related to the parent term 10.08.10.
So from a dropdown it selects Italy, from another dropdown, it selects the parent term 10.08.10 and finally from the third dropdown, it selects R5.
In the second scenario, if is not possible to create parent and child dropdowns, I can create a page where are listed all the companies that have the 10.08.10 parent term and filter them for the R5 option.
In addition, into the company detail page, I'd like to create a table, where I have a table with:
- a row for every parent term (shown with conditional output. If selected: show; if not selected: hide)
- three columns (the first for the parent terms, the second for the options from R1 to R15 and the third for the options from D1 to D15) (also here shown with conditional output).
Languages: English (English ) Spanish (Español )
Timezone: Europe/London (GMT+00:00)
Hi there
Sorry for the delay getting back to you. I have been submerged in work dealing with bugs and other issues that have arisen from the latest plugin updates and haven't been able to look at this.
I'm sorry for the delay, I will update you in the morning.
Ok, thank you.
Languages: English (English ) Spanish (Español )
Timezone: Europe/London (GMT+00:00)
From your description you don't need parent-child taxonomy terms, you need two separate taxonomies (which means far fewer terms — 841+30 = 871 instead of 841*30 = 25230).
Or 3 if the country is also a taxonomy.
So a taxonomy for country, a taxonomy for your digit-codes, and another taxonomy for your RD-codes.
Then in your View you insert filters for each taxonomy, starting with country.
Double-check that in your View you display only the available options for each input.
The taxonomy filters are not directly connected to each other, but they are indirectly connected via the data.
So if you first choose the country Italy, then the list of posts will update to only show those with the Italy term, and the other filter controls will also update to only show terms used in any of the posts now being shown.
If you then choose a digit-code term from the dropdown the list of posts will narrow down further, and the RD-codes dropdown will update to only show those terms used in this smaller list of posts.
It is not an option within Views, but you could craft a little custom JavaScript so that the second and third taxonomy dropdowns were hidden until the previous one had been selected.
If that makes sense and you will proceed on that basis I can look at the question of the table.
Your solution is perfect, but I'm very very very sorry, because I might have missed a very important information.
A company has the opportunity to select one or more digit-codes.
For example a company has these two codes:
- 01.01.01 with R1, R6
- 10.08.10 with R5, R10
In this case, creating a taxonomy with the 30 RD-codes, if a user selects 01.01.01, then, in the RD-codes dropdown, he can select also R5. This company will be shown in the results, but it shouldn't.
Hi Nigel,
I'm very close to a perfect solution 🙂
I set-up post relationships many-to-many (https://toolset.com/documentation/post-relationships/how-to-set-up-post-relationships-using-toolset/).
The relationship is between company-name and digit-codes
Then I've created a custom field for RD-codes.
My question is:
Is there the possibility to filter RD-codes when I select a digit-code from a dropdown?
For example when I select 01.01.01 code from the dropdown, I'd like to see wich RD-codes are checked.
Or do I need to create a second relationship between digit-codes and RD-codes?
Languages: English (English ) Spanish (Español )
Timezone: Europe/London (GMT+00:00)
I'm not sure why you have needed to created a relationship, what you are describing should work with taxonomies, unless I have misunderstood https://toolset.com/forums/topic/checkboxes-maximum-options/#post-906787
See my screen recording.
Once you select the first company code then it is not possible to choose a "wrong" RD code.
In your View if you go to the Screen Options tab at the very top of the page, make sure that the Query Filter checkbox is checked so that you can see the actual queries inserted when you added filter controls for the taxonomies.
Make sure the taxonomies are joined with AND and not OR.
Does that not do what you need?
Hi Nigel,
in your example, if the company "Quis tempore reiciendis ducimus et" has also 02.02.02 digit-code with R1 RD-code, it would be listed.
If I use taxonomy, I can't associated different digit-codes to RD-codes.
Hi, Nigel is out for the day but will return tomorrow to continue assisting you here.
Languages: English (English ) Spanish (Español )
Timezone: Europe/London (GMT+00:00)
Sorry if I am failing to understand the issue, but if I assign more digit-codes then the RD-code still only shows the relevant options whenever I make a choice from digit-codes.
If it should be showing something different, what should it be showing?
I think I have explained badly.
There is a connection between each digit-code and RD-codes.
A company could have:
01.01.01 ---> R1, R2
20.20.20 ---> R1, R3, R4
When I select the digit-code 01.01.01 I have to see only R1 and R2, not R3 and R4 because the last two RD-codes are connected to the digit-code 20.20.20.
To better explain, you can see the page of test company here: hidden link
I have connected company with digit-codes using relationship many-to-many (a company could be associated to more digit-codes, and a digit-code could be associated to more companies), then inside the intermediary post, I can select the RD-codes connected to the relationship company-digitCode.
Here you can see the filter: hidden link
What I'm not able, is to filter the RD-code when the digit-code is selected.
I'd like to know if there is a way to list the Parent-posts when an intermediary post satisfy my filter.