Ciao a tutti,
come si procede col nuovo codice asincrono per fare la stessa cosa?
Ad esempio:
var _gaq = _gaq || []; _gaq.push(['_setAccount', 'UA-XXXXXXX-XX']); _gaq.push(['_trackPageview']); (function() { var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'h t t p:// w w w') + '.google-analytics.com/ga.js'; var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); })(); ```Come diventerà? Io presumo:var _gaq1 = _gaq1 || [];
_gaq1.push(['_setAccount', 'UA-XXXXXXX-XX']);
_gaq1.push(['_trackPageview']);
var _gaq = _gaq || [];
_gaq2.push(['_setAccount', 'UA-YYYYYYY-YY']);
_gaq2.push(['_trackPageview']);
(function() {
var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'h t t p: //w w w') + '.google-analytics.com/ga.js';
var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
})();