homepage Welcome to WebmasterWorld Guest from 50.17.86.12
register, free tools, login, search, pro membership, help, library, announcements, recent posts, open posts,
Become a Pro Member

Home / Forums Index / Code, Content, and Presentation / HTML
Forum Library, Charter, Moderators: incrediBILL

HTML Forum

    
html redirect affiliate link - open in new window?
html redirect affiliate link
rybred



 
Msg#: 4498352 posted 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

 

swa66

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



 
Msg#: 4498352 posted 11:11 pm on Sep 21, 2012 (gmt 0)

You could call window.open in the onclick javascript to open a new window...

rybred



 
Msg#: 4498352 posted 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>

Global Options:
 top home search open messages active posts  
 

Home / Forums Index / Code, Content, and Presentation / HTML
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Home ¦ Free Tools ¦ Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About ¦ Library ¦ Newsletter
WebmasterWorld is a Developer Shed Community owned by Jim Boykin.
© Webmaster World 1996-2014 all rights reserved