Rich-text Reply

When setting an Experiment Url, can I use wildcards?

lahata 03-09-16

When setting an Experiment Url, can I use wildcards?

Hi,

 

I have a page that receives parameters in RESTful style, ie: http://www.domain.com/user/[user-id]

I defined the experiment's url on http://www.domain.com/user/ however it doesn't work.

 

How can this be solved?

 

Thanks, Lahat.

Level 1

JDahlinANF 03-09-16
 

Re: When setting an Experiment Url, can I use wildcards?

[ Edited ]

Absolutely!

That is what the regex matches are for (or substring match)

 

A regular expression like this will match any URL that contains "domain.com/user/" where there is at least one character following /user:

 

.*domain\.com\/user\/..*

e.g.,

 

matches - http://www.domain.com/user/myaccount

does not match - http://www.domain.com/user/

 

You could also set up a "substring match" that will match any URL that contains "domain.com/user":

domain.com/user

Be sure to read/watch this help article for a nifty video and examples of the different ways to set up URL targetin:

https://help.optimizely.com/hc/en-us/articles/200040835