feat: 사이트 방문 통계 비콘과 개인정보처리방침 문구 추가
This commit is contained in:
1 parent
2438ef2dd9
commit
526013058d
5 files changed
+155
-1
No files matched your search
@@ -460,5 +460,23 @@
|
||||
</section>
|
||||
|
||||
<p style="margin-top:40px; font-size:14px; color:#999;"><a href="/">ADO2 홈</a> · <a href="/terms.html">서비스 약관</a> · <a href="/privacy.html">개인정보처리방침</a></p>
|
||||
<script>
|
||||
// 방문 통계 비콘(쿠키 없음) — src/utils/visitBeacon.ts 와 같은 규칙. 끄기: localStorage 'ado2.stats.disabled' = '1'
|
||||
(function () {
|
||||
var disabled = false;
|
||||
try { disabled = localStorage.getItem('ado2.stats.disabled') === '1'; }
|
||||
catch (e) { console.warn('[VisitBeacon] localStorage unavailable:', e); }
|
||||
if (disabled || typeof navigator.sendBeacon !== 'function') return;
|
||||
try {
|
||||
navigator.sendBeacon('/api/track/view', JSON.stringify({
|
||||
path: location.pathname,
|
||||
referrer: document.referrer || null,
|
||||
utm_source: new URLSearchParams(location.search).get('utm_source')
|
||||
}));
|
||||
} catch (e) {
|
||||
console.warn('[VisitBeacon] send failed:', e);
|
||||
}
|
||||
})();
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
Reference in new issue
Block a user