Rich-text Reply

Regular Expression Help!!

vitafiveAdmin 03-04-17
Accepted Solution

Regular Expression Help!!

Hi, 

 

I am trying to find out how to get my page to load for checkout. For some reason when I enter shop.vitafive.com/v2/plans/8858/checkout and I put in shop.vitafive.com/v2/plans/.*/checkout and it gave me the companies error page. Can someone please tell me what I did wrong? 

 

tomfuertes 03-04-17
 

Re: Regular Expression Help!!

You regular expression is correct and/or will match that page. If you'd like to update it you can make it more clear by saying "only match digits" instead of "match all characters"

 

shop\.vitafive\.com\/v2\/plans\/\d+\/checkout

Sounds like the bug is that Optimizely's editor won't work well on checkout pages since you need to have something in your cart. See their help article on loading gated content: 

 

https://help.optimizely.com/Troubleshoot_Problems/Troubleshooting%3A_Can't_load_a_gated_page_that_re...

____
- Tom Fuertes | CTO @ CROmetrics / LinkedIn
"Most Impactful Use of Personalization" and "Experience of the Year" Optie award winner.


Experimentation Hero
JasonDahlin 03-06-17
 

Re: Regular Expression Help!!

Did you use the regex in your URL editor?

shop.vitafive.com/v2/plans/.*/checkout 

That won't work.  It needs to be an actual URL, not a regex for a URL.

 

Also, as @tomfuertes suggested, you may need to use the homepage URL for the editor then use "interactive" mode to navigate your site and add something to your cart before entering checkout.

--Jason Dahlin
Analytics and Testing Guru Smiley Happy
Experimentation Hero

Re: Regular Expression Help!!

Awesome! I got it to load through the interactive mode. But now I am just having issues with people going to it because the only page it will go to is the one with the numbers 24683. How can I change that to any numbers?

JasonDahlin 03-06-17
 

Re: Regular Expression Help!!

If you use the regular expression you listed in your original post or the modified version that @tomfuertes suggested as your "URL Targeting", users should be entering the experiment.

Recap:
for the editor, use an explicit URL that you can navigate to, use interactive mode to reach the page that you want to modify
for the URL Targeting, use the regular expression,
--Jason Dahlin
Analytics and Testing Guru Smiley Happy
Experimentation Hero

Re: Regular Expression Help!!

I think I'm a little lost in your answer. When I go there on my end, I go directly to the URL: https://shop.vitafive.com/v2/plans/24234/checkout

 

Will this give it to everyone or just someone that hits 24234? 

 

JasonDahlin 03-06-17
 

Re: Regular Expression Help!!

\When editing your experiment, in the "Options" drop down, notice the two items "Editor Settings" and "URL Targeting".

 

The URL you enter in "Editor Settings" is probably going to be your homepage and you'll use "Interactive Mode" to navigate to the page you actually want to modify.  This way you can use the WYSIWYG editor on your checkout page.

 

The URL you enter in "URL Targeting" will be the regular expression such as:

shop\.vitafive\.com\/v2\/plans\/\d+\/checkout
--Jason Dahlin
Analytics and Testing Guru Smiley Happy
Experimentation Hero

Re: Regular Expression Help!!

Wow! Thank you sooooo much! You are a huge help! I have been working on this since November! Thank you thank you thank you!!