954,359 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Have something to say? Contribute New Article Reply to this Article

Google Website Optimizer Cross-Domain Tracking - Outbound Link Doesn't Work

Hi all, I've been searching for hours for an answer to this. I can never get help from the google forums, so thought I'd try here. I wasn't sure whether I should post in pay-per-click or web design, but I figure PPC people have experience with this kind of thing.

I'm trying to get google website optimizer (gwo) cross-domain tracking working with the asynchronous code described here: http://www.google.com/support/websiteoptimizer/bin/answer.py?hl=en&answer=151978

My outbound link looks like this:

<a href="http://secure.ultracart.com" onclick="_gaq.push(['_link', 'http://secure.ultracart.com']); return false;">link</a>


But when I click on that outbound link, it doesn't go to the other website. It works if I remove the return false; but that stops the gwo conversion from registering.

I thought it might be a javascript conflict, so I made this simple test file, and it still doesn't work: http://www.smilinggardener.com/files/test.php

Is there someone here familiar with gwo who knows what the problem might be? If you look at the page source of my test.php, I think the code is perfect. Thanks very much for any advice you can give me.

Phil

philraymond
Newbie Poster
3 posts since Oct 2011
Reputation Points: 10
Solved Threads: 0
 

Hi Phil,

Unfortunately I have absolutely no experience at all with Website Optimizer, so I probably can't be of much help. However, I noticed that http://secure.ultracart.com automatically redirects to https://secure.ultracart.com . I'm wondering if the cross-domain thing doesn't work when switching from the http protocol to https?

Have you tried to see if the link works when only unsecured pages are involved? Just something to rule out.

cscgal
The Queen of DaniWeb
Administrator
19,421 posts since Feb 2002
Reputation Points: 1,474
Solved Threads: 229
 
Have you tried to see if the link works when only unsecured pages are involved? Just something to rule out.

Thanks so much for the idea, but it doesn't seem to matter what I use for a url.

philraymond
Newbie Poster
3 posts since Oct 2011
Reputation Points: 10
Solved Threads: 0
 

Does all the code work fine when it's all on the same domain?

I didn't notice the Control Script on your test page mentioned in the documentation page you linked to.

cscgal
The Queen of DaniWeb
Administrator
19,421 posts since Feb 2002
Reputation Points: 1,474
Solved Threads: 229
 

Does all the code work fine when it's all on the same domain?

I didn't notice the Control Script on your test page mentioned in the documentation page you linked to.

The control script is there, right at the top. ""

Yes, I've never had any problem with scripts when they're on the same domain. The problem is that the "return false" on my link is causing the link to not work. I believe that is what "return false" is designed to do, but I think I read somewhere that the "_gaq.push(['gwo._setAllowLinker', true]);" is supposed to counteract it, to allow the link to work.

philraymond
Newbie Poster
3 posts since Oct 2011
Reputation Points: 10
Solved Threads: 0
 

The control script is what is below the _udn = "none"; line. I'm really not sure though :( I don't know what else to suggest to you, your code does look just like the sample.

cscgal
The Queen of DaniWeb
Administrator
19,421 posts since Feb 2002
Reputation Points: 1,474
Solved Threads: 229
 

This article has been dead for over three months

Post: Markdown Syntax: Formatting Help
You
View similar articles that have also been tagged: