gtag 추가
This commit is contained in:
@@ -191,8 +191,29 @@
|
||||
}
|
||||
|
||||
</style>
|
||||
<!-- Google Tag Manager -->
|
||||
<script>(function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start':
|
||||
new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0],
|
||||
j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src=
|
||||
'https://www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f);
|
||||
})(window,document,'script','dataLayer','GTM-PPDRKT7Q');</script>
|
||||
<!-- End Google Tag Manager -->
|
||||
<script>
|
||||
// 페이지 진입 시 GA 페이지뷰 이벤트 전송
|
||||
window.dataLayer = window.dataLayer || [];
|
||||
window.dataLayer.push({
|
||||
event: 'page_view',
|
||||
page_title: document.title,
|
||||
page_path: window.location.pathname,
|
||||
page_location: window.location.href
|
||||
});
|
||||
</script>
|
||||
</head>
|
||||
<body>
|
||||
<!-- Google Tag Manager (noscript) -->
|
||||
<noscript><iframe src="https://www.googletagmanager.com/ns.html?id=GTM-PPDRKT7Q"
|
||||
height="0" width="0" style="display:none;visibility:hidden"></iframe></noscript>
|
||||
<!-- End Google Tag Manager (noscript) -->
|
||||
<div class="container">
|
||||
<h1>볼링공 속도 계산기</h1>
|
||||
|
||||
@@ -206,8 +227,14 @@
|
||||
<p>볼링공이 파울라인을 지날 때 '시작'을 누르고, 헤드핀에 도달할 때 '정지'를 누르세요.</p>
|
||||
<div class="stopwatch-display" id="stopwatch-display">00:00.000</div>
|
||||
<div class="stopwatch-container">
|
||||
<button class="toggle-btn" id="toggle-btn">시작</button>
|
||||
<button class="reset-btn" id="reset-btn">초기화</button>
|
||||
<button class="toggle-btn" id="toggle-btn"
|
||||
onclick="dataLayer.push({event:'button_click', event_category:'볼스피드', event_label:'스톱워치'});">
|
||||
시작
|
||||
</button> <!-- [GA] 시작 버튼 클릭 추적 -->
|
||||
<button class="reset-btn" id="reset-btn"
|
||||
onclick="dataLayer.push({event:'button_click', event_category:'볼스피드', event_label:'초기화'});">
|
||||
초기화
|
||||
</button> <!-- [GA] 초기화 버튼 클릭 추적 -->
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -229,8 +256,8 @@
|
||||
</div>
|
||||
|
||||
<div class="buttons">
|
||||
<button onclick="calculateSpeed()">계산하기</button>
|
||||
<button onclick="resetValues()">초기화</button>
|
||||
<button onclick="dataLayer.push({event:'button_click', event_category:'볼스피드', event_label:'계산하기'}); calculateSpeed()">계산하기</button> <!-- [GA] 계산하기 버튼 클릭 추적 -->
|
||||
<button onclick="dataLayer.push({event:'button_click', event_category:'볼스피드', event_label:'계산초기화'}); resetValues()">초기화</button> <!-- [GA] 계산초기화 버튼 클릭 추적 -->
|
||||
</div>
|
||||
|
||||
<div class="results" id="results">
|
||||
|
||||
Reference in New Issue
Block a user