# Conditional Logic Function

## Steps to manage:

{% stepper %}
{% step %}
**From Option set, select the option you want to apply conditional logic**&#x20;

<figure><img src="https://3294420404-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FyKpeSoGW2SR7i4BJqoeq%2Fuploads%2FOO5LF4Bl0p13IATBeHVY%2Fimage.png?alt=media&#x26;token=8b7241e1-6539-4497-b628-0f30639691b0" alt=""><figcaption></figcaption></figure>
{% endstep %}

{% step %}
**Turn On Conditional Logic**\
On the left side, in the **Option Configuration** panel, find and check the box called **"Conditional Logic Options."**

<figure><img src="https://3294420404-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FyKpeSoGW2SR7i4BJqoeq%2Fuploads%2F1MWDCKHzhbiINsyBBTlV%2Fimage.png?alt=media&#x26;token=96560d49-c96c-45bb-8fe3-c28ff9239ef6" alt=""><figcaption></figcaption></figure>
{% endstep %}

{% step %}
**Choose What to Match**

Select whether you want to base your conditions on the **previous option** or **Shopify variants.**

<figure><img src="https://3294420404-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FyKpeSoGW2SR7i4BJqoeq%2Fuploads%2FYoAJxrHKyuz5XAxdLvgr%2Fimage.png?alt=media&#x26;token=8e3d27c4-8dbe-45c5-8216-f77b4537fc5b" alt=""><figcaption></figcaption></figure>

**For Shopify variants, it is a must to write down exactly the Variant name on products**&#x20;

<figure><img src="https://3294420404-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FyKpeSoGW2SR7i4BJqoeq%2Fuploads%2F6RpSf0Ss9i5WsR1j91pP%2Fimage.png?alt=media&#x26;token=a9be9673-aa48-41b4-b855-621e1a5b604d" alt=""><figcaption></figcaption></figure>
{% endstep %}

{% step %}
**Set Your Display Rules**\
Decide when the field should appear or disappear based on the conditions you create:

* **Show:** The field will only show up if *all* conditions are true. If not, it will stay hidden.
* **Hide:** The field will hide if *all* conditions are true. Otherwise, it will show.

<figure><img src="https://3294420404-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FyKpeSoGW2SR7i4BJqoeq%2Fuploads%2FdD9SQQHruXh5Vbr5PaMJ%2Fimage.png?alt=media&#x26;token=9da3cec8-7a64-45d5-893b-dcccfa660703" alt=""><figcaption></figcaption></figure>
{% endstep %}

{% step %}
**Decide How Conditions Work Together**

* **All Conditions (AND):** The field reacts only if *every* condition is true.
* **Any Condition (OR):** The field reacts if *at least one* condition is true.

<figure><img src="https://3294420404-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FyKpeSoGW2SR7i4BJqoeq%2Fuploads%2F19z2HTjtIvARVjmV8dZ1%2Fimage.png?alt=media&#x26;token=5469cfbd-47c7-499d-a877-33ffdfac00c7" alt=""><figcaption></figcaption></figure>
{% endstep %}

{% step %}
**Set Conditions Between Elements**

Here are the condition types you can use to link elements:

* **Is equal to:** Show the field when the previous option exactly matches your selected value.
* **Is not equal to:** Show the field when the previous option does *not* match your selected value.
* **Is greater than:** (For number fields) Show the field when the previous option is greater than a certain number you set.
* **Is less than:** (For number fields) Show the field when the previous option is less than a certain number you set.
* **Starts with:** Show the field when the previous option starts with the value you specify.
* **Ends with:** Show the field when the previous option ends with the value you specify.
* **Contains:** Show the field when the previous option contains the value you specify.
* **Does not contain:** Show the field when the previous option *does not* contain the value you specify.

<figure><img src="https://3294420404-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FyKpeSoGW2SR7i4BJqoeq%2Fuploads%2F80R6EX9FKzF20G4QbHqO%2Fimage.png?alt=media&#x26;token=c21ebb4e-0b90-4e88-a563-e18125c19c14" alt=""><figcaption></figcaption></figure>

* **For Text option type (Text/Textarea)**, it allows set up the condition of characters number: To show an element if the text field is filled out the the number of characters you set up:&#x20;

<figure><img src="https://3294420404-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FyKpeSoGW2SR7i4BJqoeq%2Fuploads%2FGgmU97XdUpktcpsbnVs4%2Fimage.png?alt=media&#x26;token=0d211de0-a672-43e5-a84b-6894f9a9306a" alt=""><figcaption></figcaption></figure>

<figure><img src="https://3294420404-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FyKpeSoGW2SR7i4BJqoeq%2Fuploads%2FDjJzBINiQqrokBmTSd43%2Fimage.png?alt=media&#x26;token=d784e905-dd67-4896-8b99-11b366876e9e" alt=""><figcaption></figcaption></figure>

* **For** **Selection option type** **(Dropdown/Checkbox/Button/Swatch),** it allows set up the condition of selection number. To show an element if the previous option is selected with the number you set up

<figure><img src="https://3294420404-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FyKpeSoGW2SR7i4BJqoeq%2Fuploads%2FTczqRr9g10OaJ3Gis1h3%2Fimage.png?alt=media&#x26;token=b2e617af-b448-4c37-9f51-51f19c1f6c06" alt=""><figcaption></figcaption></figure>

<figure><img src="https://3294420404-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FyKpeSoGW2SR7i4BJqoeq%2Fuploads%2FC8gEKkHcOSsBWMvVGmrl%2Fimage.png?alt=media&#x26;token=9cf2609e-1edb-4034-abe3-fe40ae1cbf99" alt=""><figcaption></figcaption></figure>

* **For Upload file element,** it allows set up to show an element depending on the number of file you set:&#x20;

<figure><img src="https://3294420404-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FyKpeSoGW2SR7i4BJqoeq%2Fuploads%2FpBvM3qIL3IAog385oxwf%2Fimage.png?alt=media&#x26;token=83e3190e-e6af-40b9-b6f7-d9cc2753a9b5" alt=""><figcaption></figcaption></figure>
{% endstep %}
{% endstepper %}

📧 **Need Help?**\
If you run into any issues while setting up your option set, feel free to reach out to us at **Chat** or email **<contact@globosoftware.net>**.

We’re always here and happy to help — with sincerity and care!
