Load Rules - Wild Cards?

Gold Contributor
Gold Contributor
What is the proper usage for wildcards in load rules? For example, I want my load rule only to fire on domain.net (not domain.org or domain.com), but we have multiple testing environs for each domain (devdomain.net, testdomain.net). I previously tried to use a wildcard and it did not seem to work. rather than having to make: if dom.domain CONTAINS_IGNORE_CASE testdomain.net if dom.domain CONTAINS_IGNORE_CASE devdomain.net if dom.domain CONTAINS_IGNORE_CASE domain.net ad infinitum I'd like to make something like: if dom.domain CONTAINS_IGNORE_CASE *.net What is the proper format?
4 REPLIES 4

Load Rules - Wild Cards?

Employee Emeritus
Hey Kevin, Currently there aren't wildcards available, but could you just do: If domain contains (ignore case) domain.net This will load on testdomain.net, devdomain.net and any other domains that end with domain.net, but will not load on domains with .org or .com or any other ending. OR you can do domain ends with ".net" This is getting a little more broad and will actually fulfill the "*.net" requirement because any domain that ends with .net will load that tag. Hope this helps

Load Rules - Wild Cards?

Employee Emeritus
I think there are probably several options here based on what you describe. If the above is exactly the case then the simplest solution should be to use the following statement: domain (dom) ENDS WITH (IGNORE CASE) .net Alternatively, you could set up a lookup table extension scoped to All Tags that handles the various conditions in a single place and sets a flag based on the evaluation of the lookup. Your load rule would then be based on the value of the flag as determined by the lookup table. Finally, if you're comfortable with REGEX and your actual use case is more complex than the above, REGEX is one of the operators you can use in the condition for your load rule.

Load Rules - Wild Cards?

Bronze Contributor
Bronze Contributor

Where can one find how to use the REGEX operator

Load Rules - Wild Cards?

Tealium Employee

@gauravdani

 

The regular expression you enter into the input box will be used as is within the test() method.

 

So you can enter something like:

/tealium/i

Then, if case insensitive "tealium" is found within the variable you've selected to test, then the condition will evaluate to true. Otherwrise, if case insensitive "tealium" is NOT found within the variable you've selected to test, then the condition will evaluate to false.

 

Remember, the purpose of load rules is to evaluate to true or false so that iQ can determine which tags to fire.

 

Please let me know if you have any more questions!

Public