Conditional options
Conditional options are part of AddOnBoss Pro.
Not every choice applies to every customer. Thread colour only matters once someone has chosen embroidery. A conditional rule keeps the page short and clear by showing a later choice only when an earlier one calls for it.
Set a rule
Section titled “Set a rule”On the later set, field or upload, set a rule that points at an earlier question and a value: Available when Finish is Embroidered. The rule reads as a sentence and you never type any syntax.
A rule can point at an option set or at a field. Pointing at a field is what lets a tick box govern something: Hidden when Use my own artwork is ticked.
What a condition can ask
Section titled “What a condition can ask”Every question can be tested five ways:
- is and is not, for one particular answer.
- any of these, for a short list. Occasion is any of Birthday, Anniversary is one condition, not three rules.
- has been answered and is empty, which ignore the answer itself and ask only whether the customer gave one.
A number field can be tested three more ways, because a number is the only answer where size means anything:
- more than, less than and exactly. Quantity is more than 50 reveals a bulk-artwork note that nobody ordering two ever sees.
Several conditions in one rule
Section titled “Several conditions in one rule”A rule can hold more than one condition, and they group. Conditions inside a group must all be true; any one group being satisfied is enough. Reading it aloud gives you the sentence the editor shows: this group and this group, or that group.
That is what lets (Finish is Embroidered and Quantity is more than 25) or (Finish is any of Printed, Vinyl) be one rule rather than a tangle of separate ones.
A rule may only look upwards
Section titled “A rule may only look upwards”A rule may only point at a question asked above it. You cannot depend on an answer nobody has been asked for yet, which is both the honest reading and the reason a rule can never chase its own tail. If the question you want sits below, drag it above first; the editor names it and says so rather than quietly leaving it out of the list.
If you remove the question a rule depends on, the rule is not silently emptied and it does not start behaving as though it were satisfied. It pauses, keeping what it said, so you can point it at a new question and carry on. A rule that quietly became "always true" would start charging for choices that no longer apply, which is exactly the failure worth refusing.
Show or hide
Section titled “Show or hide”A rule runs in either direction and you choose which.
- Show when is the original behaviour. The dependent question stays locked until the rule is met.
- Hide when inverts it. The question is there from the start and goes when the rule is met.
Hiding matters more than it first looks. “Tick this box and the upload goes away” is a shape shops ask for constantly, and without a hide direction the workaround is a trap: hide when (A or B) is the same as show when (not A and not B), which means flipping the operator and the join together. Nobody gets that right twice in a row. So the direction is a setting you pick, not a puzzle you solve.
How it looks to the customer
Section titled “How it looks to the customer”The dependent choice does not vanish. It sits in place, visible but locked, under a plain line like Available when Finish is Embroidered, and it unlocks the moment that value is picked. Showing it rather than hiding it means a customer, and assistive technology, can always see the choice exists and what unlocks it. The moment the trigger value changes away again, the choice relocks.
A choice that appears and disappears makes a page feel unpredictable and can hide that a further decision exists at all. Keeping it in place, with its reason on show, means the whole configuration reads as one story from top to bottom.
A locked choice is inert
Section titled “A locked choice is inert”While a choice is locked it is completely inert: nothing it holds is charged, its required flag never fires, and anything already chosen or typed in it clears until it unlocks. So a customer can never be charged for, or blocked by, a choice that does not apply to them. This holds on the server as well as on the page, so a value cannot be slipped past a locked rule.
What can be gated
Section titled “What can be gated”The same rule works on an option set, a field, and a file upload. So “upload your logo” can wait until the customer has chosen a printed finish, and a “thread colour” dropdown can wait until they have chosen embroidery, all on the one page.
On the quantity grid
Section titled “On the quantity grid”The quantity grid is one line covering every colour and size at once, which changes what a rule can mean there.
A rule that starts from a field works normally: the tick box is asked once for the whole grid, so the question it governs has a single answer to read.
A rule that starts from an option set stands down. The grid’s whole purpose is that every colour and size is ordered together, so there is no single pick for the rule to look at, and the question it governs is simply offered.
A worked example
Section titled “A worked example”A printed board product offers a Finish set with Plain and Printed. A Upload your artwork field and a Print area set both carry the rule Available when Finish is Printed. A customer buying a plain board sees the two print choices locked and is charged nothing for them; a customer choosing Printed unlocks both and fills them in. One product serves both without a separate listing.