Cross domain tracking and target _blank
-
Hi,
I found a little problem with Cross Domain Tracking when target is set to _blank. The link don’t open in a new window.
I found a workaround. “_gaq.push” prevent “return false” to act normaly. So i set a timeout to “gaq.push” to force return false to execute immediately.
Here is the code replacement i make in google analytics for wordpress v4.3.5 :
frontend/class-frontend.php Line 367
replace
$trackBit = '_gaq.push([\'_link\', \'' . $matches[2] . '//' . $matches[3] . '\']); return false;"';
by
$trackBit = 'setTimeout("_gaq.push([\'_link\', \'' . $matches[2] . '//' . $matches[3] . '\'])",100); return false;';
Is there plan to fix these problem ?
Thanks
https://www.ads-software.com/plugins/google-analytics-for-wordpress/
- The topic ‘Cross domain tracking and target _blank’ is closed to new replies.