Digioh Conditions Overview

Conditions empower you to target your website views with laser precision. Display a box to users based on device, referral source, geolocation, login status and more! There are so many options, but this guide goes over a few commonly used conditions.

Adding a Condition

You can add conditions from the Digioh Dashboard or the Editor.

From the Dashboard, just click on the “Add/Edit” button in the conditions column for the box you want to edit.

From the Editor, scroll down to the Conditions section on the left and click “Edit Conditions.”

Click “Add Conditions” to start adding rules.

Then click “Add New Rule.”

Choose the rule you want to add from the dropdown.

Testing a Lightbox

First thing’s first, let’s make a test box. Conditions make it easy to test a box by only pushing it to a specific test URL, rather than your entire site.

Current Page URL Rule

The Current Page URL rule lets us show a lightbox on any URL. For testing purposes let’s set it up like this:

Rule: Current Page URL Contains ?LightboxTest
View Demo

Now if you add “?LightboxTest” to the end of your domain, this box will appear.

Device Type Rule

Device type lets you display boxes depending on whether your visitor is using a Desktop computer, phone or tablet.

Rule: Device Type Equals Phone
View Demo (View on Mobile)

Time on Site

Sometimes it’s a good idea to let your users browse your site for a bit before hitting them with a lightbox. Control exactly when you want the user to see a box with the Total Seconds on Page, Active Seconds on Page and Idle Seconds on Page rules.

Total Seconds on Page Rule

If you want to show a box after a user has been on the site for 3 seconds, you can make a condition that looks like this:

Rule: Total Seconds on Page Greater Than 3

Specific URLS

Using the Current Page URL rule we can control exactly which URLs to display a box.

Current Page URL Equals

With the “Equals” modifier we can display a box on an exact match URL, such as:

View Demo

Rule: Current Page URL Equals {your URL}

Without the utm code at the end, the box won’t display, giving you precise control over which visitors see this box.

Current Page URL Contains any of these

We can also show boxes on multiple URLS with the “Contains any of these” modifier.

Rule: Current Page URL Contains any of these

Now this box will appear on any pages that contain “product” or “category” in the URL.
View Product Page Demo
View Category Page Demo

Targeting New Users

The last thing you want to do is annoy your site visitors. So let’s make sure we don’t ask users who are already on your list to sign up.

Pages Navigated Rule

With the Pages Navigated Rule we can see which users have already clicked through from one of your emails in the past. If your newsletters use the UTM code utm_medium=email, then this is a breeze.

Rule: Pages Navigated URLs Does NOT contain utm_medium=email

Login Status

Another great use for boxes it to ask users to log in or sign up. We can create a condition to detect if a user is logged out currently to show them this box.

View Demo

Cookies Rule

To set up a Cookie rule, you’ll need to know a bit about how your cookies are set up. But in this example, we’ll assume the Cookie Name is “loggedin” and the Cookie Value is true or false. Since we went to focus on users that are not currently logged in, we’ll choose “false” as the value.

Rule: Cookie Contains loggedin false

User Behavior

Another great way to use conditions is to display content based on a user’s behavior. The most popular example is Exit Intent. If a user is about to exit your site before signing up or making a purchase you can offer them an amazing deal before they go!

Exit Intent Rule

The Exit Intent rule detects if a user is moving their mouse towards the address bar (or anywhere off of your site) and will trigger a box to appear.

View Demo

Rule: Exit Intent This event occurs Mouse exists window top

Display Based on Tags

With conditions we can display boxes on pages that contain the same tags. This is a great way to display content on related pages.

For our example, we’re going to make a rule that shows a specific box across multiple products from the same brand. The brand name isn’t in the URL but each page does contain a brand tag.

HTML Exists jQuery Rule

With the HTML exists jQuery rule we can choose a tag and display content on any page that contains the same tag.

View Demo

You have to copy the selector of the tag you want to reference. To do that, right click on the tag in on the page and click “Inspect” to open up your dev tools.

Then right click on the tag in the HTML code and go to “Copy” and choose “copy selector.”

Paste that into the conditions field and test it out.

Rule: HTML Exists jQuery Equals {selector}

Keep in mind, this rule is a little bit advanced so if you need help setting it up, don’t hesitate to contact support.

In fact, for our example, we had to adjust the selector a tiny bit to get it to work.

The selector we copied was:
body > div.section.cc-product-detail > div.product-details-wrap > div.w-dyn-list > div > div > a

However, to get it to work we had to be a bit more specific:
body > div.section.cc-product-detail > div.product-details-wrap > div.w-dyn-list > div > div a:contains(‘Camici’)

How did we know how to do that? Years of web development experience! So if you get stuck on this one, just let us know!

There are lots of other things you can do with conditions, but this was just a brief overview of some of the most common uses.