Google 웹 로그 분석 코드의 다음 줄이 수를 단축?Google 웹 로그 분석 코드
전체 스크립트는 다음과 같습니다 : 이렇게하면 예를 들어 서버를 테스트하기 위해 file:
프로토콜을 사용하여이 파일을로드하는 경우
<script type="text/javascript">
var _gaq = _gaq || [];
_gaq.push(['_setAccount', 'UA-XXXXXXX-X']);
_gaq.push(['_setDomainName', 'example.com']);
_gaq.push(['_trackPageview']);
(function() {
var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
ga.src = ('https:' == document.location.protocol ? 'https://' : 'http://') + 'stats.g.doubleclick.net/dc.js';
var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
})();
</script>