Analytics
3.5K members online now
Understand information in your reports and troubleshoot reporting issues such as self-referrals, (not set) data, and inaccurate information
 
Guide Me
star_border
Reply

Help:Goal and regular expressions

Explorer ✭ ✭ ✭
# 1
Explorer ✭ ✭ ✭

Hello ,

In wocommerce i have a thank you page like this:

 

/checkout/order-received/7213/?key=wc_order_58beaf1d078c1

 

I have a setup a  destination goal in GA with begin condition like this 

 

begins with /checkout/order-received/

 

and it is working ok.

 

My question is how can i do this with regular expression?

after the order received part the remaning part is dynamic for every order.

 

Thanks

1 Expert replyverified_user

Help:Goal and regular expressions

Top Contributor
# 2
Top Contributor

I'd test the following regexs -

^/checkout/order\-received/\d+/\?.*

or

^/checkout/order\-received/\d*/\?.*

 

Whole thing about regex in the help docs! :-)
https://support.google.com/analytics/answer/1034324?hl=en&ref_topic=1034375

 

Bronwyn Vourtis, Google Analytics Top Contributor
Was my response helpful? If yes, please mark it as the ‘Best Answer.’ Learn how here