Can you give me some information on how you have to change your tracking code?
Maybe this is just a little change to do. 🙂
Hi Breaking,
This is the code I manually put into templates.
<!– Piwik –>
<script type=”text/javascript”>
var _paq = _paq || [];
(function(){ var u=((“https:” == document.location.protocol) ? “https://analytics.domain.com/” : “http://analytics.domain.com/”);
var ucdn=((“https:” == document.location.protocol) ? “https://cdn.domain.com/” : “http://cdn.domain.com/”);
_paq.push([‘setSiteId’, SITE_ID]);
_paq.push([‘setTrackerUrl’, u+’piwik.php’]);
_paq.push([‘trackPageView’]);
_paq.push([‘enableLinkTracking’]);
var d=document, g=d.createElement(‘script’), s=d.getElementsByTagName(‘script’)[0]; g.type=’text/javascript’; g.defer=true; g.async=true; g.src=ucdn+’piwik.js’;
s.parentNode.insertBefore(g,s); })();
</script>
<!– End Piwik Code –>
This is Asynchronous to also help the site pages load just a little faster. Reference http://piwik.org/docs/javascript-tracking/#toc-asynchronous-tracking
If we could just copy and paste our own tracking code it would be fine. Otherwise a additional setting page to customise the tracking where we can specify all the different hosts and regenerate code.
I would be happy to help you test, and give you access to a CDN if you do not have one.
Ian
Hi Ian,
I’m currently waiting for the Piwik team to finish a feature request, see
http://ww.wp.xz.cn/support/topic/plugin-wp-piwik-piwik-asynchronous-tracking
Using a custom tracking code field (extended by wildcards) sounds good as a workaround. I’ll think about this.
Best regards
André
Hi Andre,
From looking at the history of that asynchronous feature request ( 2 years old now ) i would guess it could take a while before being completed.
But anything you can do would be really appreciated.
Ian
Feature “custom tracking code” will be part of 0.9.9.
CDN support is added in 0.9.9, release today.
0.9.9.0 released now. I hope the CDN support works fine 🙂
This new version works great for me as I have a SSL certificate. However I have realised that many users will not have SSL on the CDN’s as they are very expensive. If possible can you update the next version to allow for different hostnames 1 for http and 1 for https.
For example if your CDN is with cdn77.com then your http host maybe – cdn.domain.com but your https host would be myprefix.r.worldssl.net
Sorry I did not specify that in my earlier comments.
Alright, updated in 0.9.9.1.