Categories
Categories

Does Solid Affiliate work with caching?

Learn how to set up any WordPress caching plugin for Solid Affiliate.
Last updated on November 18, 2021

Yes, Solid Affiliate works with caching right out of the box. It has been tested with major WordPress caching plugins and popular hosting providers with built-in caching.

Solid Affiliate includes redundant referral tracking technologies to ensure an accurate and consistent visit, referral, and commission tracking system.

As a WooCommerce store owner, you’re likely using a caching solution to keep your site running quickly. In most cases, Solid Affiliate will work with caching plugin with no specific configuration changes needed by you. However, If you’ve encountered issues with referral/visits tracking, or affiliates having trouble logging in, it may be necessary to make a few changes to your caching plugin settings. They’re quick and easy, just follow the simple steps below!

In this guide, we’ll show you how to set up any WordPress caching plugin for Solid Affiliate, what to do if things go wrong, and how to test if affiliate tracking is working on your store.

Have you run into any of these?

  • Visits and referrals are not tracked.
  • Referrals are being credited to the wrong affiliate.
  • “Are you cheating?”, “Cheatin’ Uh?” errors.
  • Affiliates having trouble signing in.

These issues are most often due to caching interaction. You can quickly fix them by tweaking your caching plugins.

Setting up Solid Affiliate caching

If you’re using a caching plugin  you need to do the following:

Step 1: Exclude Solid Affiliate Pages From Your Caching Plugin

Excluding pages is reasonably straightforward in most WordPress caching plugins, simply go to your caching plugin settings, look for the exclude option, and set the following pages to be excluded:

  • Affiliate portal page
  • Affiliate registration page (if separate from the affiliate portal page)
  • Affiliate login page (if separate from the Affiliate portal)
  • Any pages using Solid Affiliate shortcodes

The pages are the main dynamic pages offered by Solid Affiliate, where the content changes based on who is looking at the page.

Step 2: Exclude Solid Affiliate Cookie From Caching

Solid Affiliate plugin creates a single tracking cookie that should be excluded from caching : solid_visit_id

Note for WordPress Multisite installations: Solid Affiliate creates separate cookies for every additional site in your network, to completely isolate the affiliate program data. The cookie will be in the format solid_visit_id-$blog_id for example solid_visit_id-2. You can read more here: Solid Affiliate on WordPress Multisite.

If the cookie is being cached, this could result in:

  • Disabling visits and referrals tracking.
  • Crediting the referral to the wrong affiliate.
  • Affiliates unable to log in.

We highly recommend excluding Solid Affiliate tracking cookies from caching.

The process to exclude the above cookie and Solid Affiliate pages vary depending on which caching plugin you use. Please refer to the documentation for your specific caching plugin for instructions on excluding URLs and cookies – it’s a common process, and most plugins make it easy for you. Below, you’ll find guides to exclude Solid Affiliate cookies and URLs in popular WordPress caching plugins.

Using Popular Caching plugins with Solid Affiliate

WP Rocket

It is very simple to exclude a page or pages from the cache.

  1. Go to WP Rocket Advanced Rules tab.
  2. Locate the box Never cache (URLs).
  3. Enter the URLs of the Solid Affiliate pages. You can either enter the full URL e.g. http://www.example.com/affiliate-portal/ or you can just enter the part after the domain name, e.g. /affiliate-portal/ . Either way will work.
  4. If you are using separate pages for registration and affiliate login, enter each one on its own line.
  5. Save settings.
Note: Whether or not you include a trailing slash at the end of the URL depends on how your site is set up. You can go to Settings → Permalinks and look at the structure you are using. If it ends with a slash (/), such as /%postname%/ (which is the most typical), you must include it when adding URLs to this box.

To prevent cached pages from being served once the Solid Affiliate cookie is set in the browser. Follow these steps:

  1. Go to WP Rocket Advanced Rules tab.
  2. Locate the box Never cache Cookies.
  3. Enter the following cookie id solid_visit_id.
  4. Save settings.

WP Fastest Cache

To exclude Solid Affiliate cookies and URLs in WP Fastest Cache:

  1. Go to WP Fastest Cache Exclude tab.
  2. Add a new rule to exclude pages with the slugs of the Solid Affiliate pages.
  3. Add a new rule to exclude cookies, and enter  solid_visit_id.
  4. Save settings.
  5. Purge all caches.

W3 Total Cache

To exclude Solid Affiliate cookies and URLs in W3 Total Cache:

  1. Navigate to Dashboard → Performance → Page Cache.
  2. In the “Never cache the following pages” field, add the slugs for Solid Affiliate pages.
  3. In the “Rejected cookies” field and add solid_visit_id.
  4. Save settings.
  5. Purge all caches.

LiteSpeed page

To exclude Solid Affiliate cookies and URLs in LiteSpeed Cache:

  1. Navigate to Dashboard → LiteSpeed Cache → Cache → Excludes tab.
  2. In the “Do Not Cache URIs” field, add the slugs for the Solid Affiliate pages.
  3. In the “Do Not Cache Cookies” field,  add solid_visit_id.
  4. Save settings.
  5. Purge all caches.

If you want to test that everything is working, refer to this guide at any time: Solid Affiliate – How to test that everything is working properly.

If you’ve tried all of these things and you’re still having issues, please contact our support team.

In this article