- Impact
- 51
I have 1 host and i have linked two domains to the same directory on my host
.se and .co
Now i want to track the domain individually on analytics
Here is the code i have used, but is it right?
<script type="text/javascript">
var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl." : "http://www.");
document.write(unescape("%3Cscript src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E"));
</script>
<script type="text/javascript">
try {
var pageTracker1 = _gat._getTracker("[UA-00000000-1]");
pageTracker._trackPageview();
} catch(err) {}
try {
var pageTracker2 = _gat._getTracker("[UA-00000000-0]");
pageTracker2._trackPageview();
} catch(err) {}
</script>
I have aded this filter to only include the hostname www\.domain\.se and then one for the .co
.se and .co
Now i want to track the domain individually on analytics
Here is the code i have used, but is it right?
<script type="text/javascript">
var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl." : "http://www.");
document.write(unescape("%3Cscript src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E"));
</script>
<script type="text/javascript">
try {
var pageTracker1 = _gat._getTracker("[UA-00000000-1]");
pageTracker._trackPageview();
} catch(err) {}
try {
var pageTracker2 = _gat._getTracker("[UA-00000000-0]");
pageTracker2._trackPageview();
} catch(err) {}
</script>
I have aded this filter to only include the hostname www\.domain\.se and then one for the .co





