Bug with JavaScript links
-
There is a problem with affiliate bannrers that use JS to transfer to the correct affiliate URL.
Here’s the original affiliate code:
<a href="https://www.siteground.com" onClick="this.href='https://www.siteground.com/wordpress-hosting.htm?afcode=123123'" ><img src="https://ua.siteground.com/img/banners/application/wordpress/250x250.gif" alt="Web Hosting" width="250" height="250" border="0"></a>
Here’s how Google Analytics for WordPress breaks it:
<a href="https://www.siteground.com?afcode=123123" onclick="javascript:_gaq.push(['_trackEvent','outbound-widget','https://www.siteground.com']);"><img src="https://ua.siteground.com/img/banners/general/comfort/250x250.gif" alt="Web Hosting" width="250" height="250" border="0"></a>
Here’s how the output should look:
<a href="https://www.siteground.com" onclick="javascript:_gaq.push(['_trackEvent','outbound-widget','https://www.siteground.com']);this.href='https://www.siteground.com/wordpress-hosting.htm?afcode=123123'" ><img src="https://ua.siteground.com/img/banners/application/wordpress/250x250.gif" alt="Web Hosting" width="250" height="250" border="0"></a>
I hope that you manage to have this fixed in the next update because there are customers complaining about this and I am positive that there are other links that are broken the same way.
Best,
Hristohttps://www.ads-software.com/plugins/google-analytics-for-wordpress/
- The topic ‘Bug with JavaScript links’ is closed to new replies.