GoogleAnalyticsで携帯のアクセス数はカウント(計上)できるのか?
■結論
出来る。
■方法
Analyticsでは通常http://www.google-analytics.com/__utm.gifのファイルに(クライアント情報を記録した)クエリをつけたリクエストをJavaScriptで行っている。このimgをベタでHTMLファイルに記述すればJavaScriptが実行できない携帯端末でもgifファイルをリクエストし、Analyticsに計上される。
■ソース
<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{
//this is your id
var pageTracker = _gat._getTracker("UA-123756-7");
pageTracker._trackPageview();
}
catch(err){}
</script>
<noscript>
<img src="http://www.google-analytics.com/__utm.gif?utmul=noscript" width="1" height="1" />
</noscript>
■注意
自己責任でお試しください。
アイデア提供元(codeなにがし)
TrackBack URL :
Comments (1)
[...] public links >> googleanalytics GoogleAnalyticsで携帯のアクセス数はカウント(計上)できるのか? First saved by kaffeina | 1 days ago Google Analytics for Beginners: How to Make the Most of [...]
ピンバック by Recent Faves Tagged With "googleanalytics" : MyNetFaves — 2008 年 10 月 10 日 @ 4:20 PM