Skip to main content

Exclude *.local domains from using activation slots

Could you please add *.local to the list of domains that do not use activation slots?

Shahjahan Jewel

Done on development branch.

Eusebiu Oprinoiu

Thank you very much, Jewel! I appreciate it.

If you want to improve this even further, you could also ignore the websites that have the environment type set to local, staging, or development. (for those edge cases that are not covered by the common localhost/staging patterns)

Shahjahan Jewel

Eusebiu OprinoiuΒ For your reference, here are all the patterns Fluent Cart's licensing module currently treats as local/staging (no activation slot used):

TLDs / domain suffixes

  • *.local (newly added)
  • *.test
  • localhost

Subdomain prefixes (e.g. staging.example.com, dev.example.com)

  • staging., stage., dev., development.
  • test., testing., qa., uat.
  • sandbox., beta., preview.

Subfolder paths (e.g. example.com/staging/)

  • /staging/, /stage/, /dev/, /development/
  • /test/, /qa/, /uat/
  • /sandbox/, /beta/, /preview/

Known managed-hosting staging domains

  • WP Engine (.wpengine.com, .wpenginepowered.com)
  • Kinsta (.kinsta.cloud)
  • SiteGround (.sg-host.com)
  • Cloudways (.cloudwaysapps.com)
  • Flywheel (.flywheelsites.com)
  • Pantheon (.pantheonsite.io)
  • DreamHost (.dreamhostps.com)
  • Pressable (.pressable.site)
  • WPMU DEV (.staging.wpmudev.host)
  • Liquid Web (.liquidweb.cloud)
  • RunCloud (.runcloud.link)
  • xCloud (.wp1.sh)

Eusebiu Oprinoiu

Thank you, Jewel!
I checked the source code before opening this thread. πŸ™‚

Thomas Oates

Shahjahan JewelΒ What about adding the .dev top level domain? I'm using that now for my dev/test WP site.

Shahjahan Jewel

Thomas OatesΒ .dev is a real popular domain. Please note, we have hooks, so you can add more top level domain extensions or sub domains support.

Nathan Foley

For reference, this is how you add .dev if that's what you wanted to do

add_filter('fluent_cart/license/staging_domains', function ($domains) {
return array_filter($domains, function ($domain) {
return $domain !== '.dev' && $domain !== 'dev';
});
});

I have one for my demo domain wpdemo.uk so a single licence can do as many installs as I want but if it goes missing its never going to activate anywhere else

add_filter('fluent_cart/license/staging_domains', function ($domains) {
return array_filter($domains, function ($domain) {
return $domain !== '.wpdemo.uk';
});
});