Understanding Boolean Operators in LoopPress
Hello artists! If you’re using LoopPress for token gating on your site, it’s essential to understand how Boolean operators work. These operators help you set specific conditions for your content access. Let’s break them down in a simple and easy-to-understand manner.
1. + (AND)
When you use the
+ operator, it means both conditions must be met.
- Example: If you have two tokens,
songB, and you want both to be required for access, you’d use:
[looppress token="songA+songB"]. This means a user must have both
songBtokens to access the content.
2. , (OR)
, operator means either of the conditions can be met for access.
- Example: For tokens
songB, if you want a user to have access with either one, you’d use:
This means having
songBwill grant access.
3. ! (NOT)
! operator excludes users with a specific token.
- Example: If you want to grant access to everyone except those with the
songBtoken, you’d use:
4. * (MULTIPLE)
* operator indicates multiple instances of a token.
- Example: If you want a user to have access only if they have three instances of the
songAtoken, you’d use:
5. () (Parentheses)
Just like in math, parentheses
() determine the order of operations. Conditions inside the parentheses are processed first.
- Example: If you want users to have access if they have both
songB, OR if they don’t have
songC, you’d use:
How to Implement on Your Site:
- Determine the conditions you want for access to your content.
- Use the appropriate Boolean operators as explained above.
- Insert the
[looppress contract="..."]shortcode into your post or page where you want the gated content.
Remember, these operators help you create flexible and specific conditions for your content. Tailor them to your needs and ensure your fans have the right access!