Analytics
1.6K members online now
1.6K members online now
Dive into multiple domain (Cross/Sub) tracking, implementing Ecommerce and Enhanced Ecommerce, setting up Event tracking, and Universal Analytics code.
 
Guide Me
star_border
Reply

Content Experiment advice for the inexperienced

Visitor ✭ ✭ ✭
# 1
Visitor ✭ ✭ ✭

Hi all

 

I'm attempting to run the following content experiment, but it's not going well so I'd love some advice.

Original: http://domain.net/2016/index.php (the site's homepage)

vs

Variant: http://domain.net/2016/variant.php (a variant of the site's homepage)

 

No problems getting the variants served, however when the variant page is served, all navigational links are broken. I'm not certain that I'm setting the experiment up correctly.

If I specify static URLs in the experiment setup, all links away from the variant (to other pages) redirect to the variant. 

 

If I specify relative URLs in the experiment setup, all links away from the variant (to other pages) result in a 404.

 

My site hides the "index.php" for a given url using htaccess:

#Remove Index.html
RewriteCond %{REQUEST_URI} index\.html
RewriteRule ^(.*)/index\.html$ /$1/ [R=301,L]


I wondered if that has anything to do with the problem, but I would love some help.


Apologies if this is an obvious or common question - I've tried plenty of searching, to no avail Smiley Sad 

1 Expert replyverified_user
1 ACCEPTED SOLUTION

Accepted Solutions
Marked as Best Answer.
Solution
Accepted by topic author Matthew T
December 2015

Re: Content Experiment advice for the inexperienced

Google Employee
# 2
Google Employee
Have you added the experiment snippet on all these pages that the links point to?

Be aware that the experiment snippet will redirect on any page that is added on.

So you should probably add it only on "http://domain.net/2016/index.php" and not on all other pages.

View solution in original post

Marked as Best Answer.
Solution
Accepted by topic author Matthew T
December 2015

Re: Content Experiment advice for the inexperienced

Google Employee
# 2
Google Employee
Have you added the experiment snippet on all these pages that the links point to?

Be aware that the experiment snippet will redirect on any page that is added on.

So you should probably add it only on "http://domain.net/2016/index.php" and not on all other pages.

Re: Content Experiment advice for the inexperienced

Visitor ✭ ✭ ✭
# 3
Visitor ✭ ✭ ✭
Ah! Thank you Dimitris Smiley Happy

I'd added the experiment snippet to a php include which was common to all pages.
It's now on the homepage only and working fine.

That is, as I suspected, quite obvious. Smiley Happy

Thanks for your help!