Welcome to WebmasterWorld Guest from 54.145.173.36

Forum Moderators: incrediBILL

Message Too Old, No Replies

html redirect affiliate link - open in new window?

html redirect affiliate link

   
6:12 pm on Sep 21, 2012 (gmt 0)



Hi, just wondering how you suggest getting the redirect page to open up in a new window. I'm a newb, help me out

I currently am tracking my outbound links in google analytics using code as follows:

<a href="http://www.mysite.com/product.html" target="_blank" onClick="recordOutboundLink(this, 'Outbound Links', 'MyOutboundLink1');return false;"></a>

the .html address is the redirect page to my affiliate link


It doesn't seem to consider the target="_blank" when the onclick tracking is in there.

Here is my redirection page:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta http-equiv="refresh" content="0; url=http://www.affiliateprogram.com/products/some_product?affiliateid=482196">
<title>Affliate product 1</title>
</head>

<body>
</body>
</html>



Any suggestions on how to make it open in a new window? For links that don't have the outbound links tracking code, it works fine obviously.

Thanks
11:11 pm on Sep 21, 2012 (gmt 0)

WebmasterWorld Senior Member swa66 is a WebmasterWorld Top Contributor of All Time 10+ Year Member



You could call window.open in the onclick javascript to open a new window...
11:55 pm on Sep 21, 2012 (gmt 0)



could you show me how to do that, can you put the window.open into this link for me please, i'm really clueless how to do that properly, your help is much appreciated

<a href="http://www.mysite.com/product.html" target="_blank" onClick="recordOutboundLink(this, 'Outbound Links', 'MyOutboundLink1');return false;"></a>