3

I am trying to set up some goals in Google Analytics and I have everything but one of them working.

I need to know how to "cut off" an expression essentially.

So I have pages that are structured like the following where the CLIENT-NAME portion is dynamic based on client being viewed:

STEP 1 - /client/CLIENT-NAME/

STEP 2 - /client/CLIENT-NAME/product/

STEP 3 - /client/CLIENT-NAME/cart/

STEP 4 - /client/CLIENT-NAME/checkout/

STEP 5 - /client/CLIENT-NAME/success/

I created expressions for all of the above except the first one.

The following expression works for all of my pages except the top one:

/client/.*/product/

Insert cart/checkout/success where product is for any of the other funnel steps to be successful.

What I want is an expression that covers that step 1/top option and ignores anything that trails after that last / after CLIENT-NAME because if we count that, everything that follows counts for a different event type and the number is inflated quite a bit since it's counting pageviews that are for other steps in my funnel.

Is this possible in GA?

  • Try `/client/([^/]+)/?$` – Wiktor Stribiżew Sep 06 '19 at 17:47
  • If you just match `/client/CLIENT-NAME/`without an event you have to know for sure this will/could only happen once within a whole list of events for the client. Imo, Its better to use a single event on all the clients. Use the event that best describes what it is you want to track. Using _nothing_ like this `/client/([^/]+)/?$` tells you absolutely nothing. But, if its just a one time header, then ok. –  Sep 06 '19 at 18:08
  • @WiktorStribiżew that worked perfectly, thank you so much! – Emilee Walch Sep 06 '19 at 18:12

0 Answers0