ev-cook-siteurl / index.html
seawolf2357's picture
Update index.html
e9fa16f verified
<!DOCTYPE html>
<html lang="ko">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>EV Cook Site - ๋ฐฉ๋ฌธ์ž ์ถ”์  ํ™œ์„ฑํ™”</title>
<style>
* {
margin: 0;
padding: 0;
box-sizing: border-box;
}
body {
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
min-height: 100vh;
color: #333;
}
.header {
background: rgba(255, 255, 255, 0.95);
padding: 20px 0;
box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}
.header-content {
max-width: 1200px;
margin: 0 auto;
padding: 0 20px;
display: flex;
justify-content: space-between;
align-items: center;
}
.logo {
font-size: 28px;
font-weight: bold;
color: #1e3c72;
}
.nav {
display: flex;
gap: 30px;
}
.nav a {
color: #333;
text-decoration: none;
font-weight: 500;
transition: color 0.3s;
}
.nav a:hover {
color: #1e3c72;
}
.main-container {
max-width: 1200px;
margin: 50px auto;
padding: 0 20px;
}
.hero-section {
background: white;
border-radius: 20px;
padding: 60px;
text-align: center;
box-shadow: 0 20px 60px rgba(0,0,0,0.1);
margin-bottom: 40px;
}
.hero-section h1 {
font-size: 48px;
color: #1e3c72;
margin-bottom: 20px;
}
.hero-section p {
font-size: 20px;
color: #666;
margin-bottom: 30px;
}
.tracking-status {
background: #e8f5e9;
border: 2px solid #4caf50;
border-radius: 10px;
padding: 20px;
margin: 20px 0;
}
.tracking-status h3 {
color: #2e7d32;
margin-bottom: 10px;
}
.info-grid {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
gap: 20px;
margin-top: 40px;
}
.info-card {
background: white;
padding: 30px;
border-radius: 15px;
box-shadow: 0 10px 30px rgba(0,0,0,0.1);
transition: transform 0.3s;
}
.info-card:hover {
transform: translateY(-5px);
}
.info-card h3 {
color: #1e3c72;
margin-bottom: 15px;
font-size: 24px;
}
.info-card p {
color: #666;
line-height: 1.6;
}
.status-indicator {
display: inline-flex;
align-items: center;
gap: 8px;
background: #f5f5f5;
padding: 8px 16px;
border-radius: 20px;
font-size: 14px;
}
.status-indicator.active {
background: #e8f5e9;
color: #2e7d32;
}
.status-dot {
width: 8px;
height: 8px;
border-radius: 50%;
background: #4caf50;
animation: pulse 2s infinite;
}
@keyframes pulse {
0% {
box-shadow: 0 0 0 0 rgba(76, 175, 80, 0.7);
}
70% {
box-shadow: 0 0 0 10px rgba(76, 175, 80, 0);
}
100% {
box-shadow: 0 0 0 0 rgba(76, 175, 80, 0);
}
}
.tracking-details {
background: #f8f9fa;
padding: 20px;
border-radius: 10px;
margin-top: 20px;
font-family: monospace;
font-size: 14px;
}
.tracking-details .row {
display: flex;
justify-content: space-between;
padding: 8px 0;
border-bottom: 1px solid #e0e0e0;
}
.tracking-details .row:last-child {
border-bottom: none;
}
.tracking-details .label {
font-weight: bold;
color: #555;
}
.tracking-details .value {
color: #1e3c72;
}
.buttons {
display: flex;
gap: 15px;
margin-top: 30px;
justify-content: center;
flex-wrap: wrap;
}
button {
padding: 12px 30px;
background: #1e3c72;
color: white;
border: none;
border-radius: 8px;
font-size: 16px;
font-weight: 500;
cursor: pointer;
transition: all 0.3s;
}
button:hover {
background: #2a5298;
transform: translateY(-2px);
box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}
button.secondary {
background: #757575;
}
button.secondary:hover {
background: #616161;
}
.footer {
text-align: center;
padding: 40px 20px;
color: white;
margin-top: 60px;
}
.console-hint {
background: #fff3cd;
border: 1px solid #ffeaa7;
padding: 15px;
border-radius: 8px;
margin: 20px 0;
text-align: center;
}
.console-hint code {
background: #f8f9fa;
padding: 2px 6px;
border-radius: 3px;
font-family: monospace;
}
.debug-panel {
background: #f0f0f0;
border: 2px solid #999;
border-radius: 10px;
padding: 20px;
margin: 20px 0;
display: none;
}
.debug-panel h3 {
color: #333;
margin-bottom: 10px;
}
.debug-log {
background: white;
border: 1px solid #ccc;
border-radius: 5px;
padding: 10px;
height: 200px;
overflow-y: auto;
font-family: monospace;
font-size: 12px;
}
.debug-log .log-entry {
margin: 2px 0;
padding: 2px 5px;
}
.debug-log .success {
color: #2e7d32;
background: #e8f5e9;
}
.debug-log .error {
color: #c62828;
background: #ffebee;
}
.debug-log .info {
color: #1565c0;
background: #e3f2fd;
}
</style>
</head>
<body>
<header class="header">
<div class="header-content">
<div class="logo">โšก EV Cook</div>
<nav class="nav">
<a href="#home">ํ™ˆ</a>
<a href="#about">์†Œ๊ฐœ</a>
<a href="#tracking">์ถ”์ ์ •๋ณด</a>
<a href="#contact">๋ฌธ์˜</a>
</nav>
</div>
</header>
<div class="main-container">
<section class="hero-section">
<h1>EV Cook ์ถ”์  ๋ฐ๋ชจ ์‚ฌ์ดํŠธ</h1>
<p>์ด ์‚ฌ์ดํŠธ๋Š” ๋ฐฉ๋ฌธ์ž ์ถ”์  ์‹œ์Šคํ…œ์ด ํ™œ์„ฑํ™”๋˜์–ด ์žˆ์Šต๋‹ˆ๋‹ค</p>
<div class="tracking-status">
<h3>๐Ÿ” ์ถ”์  ์ƒํƒœ</h3>
<div class="status-indicator active">
<span class="status-dot"></span>
<span>์ถ”์  ํ™œ์„ฑํ™”๋จ</span>
</div>
<div class="tracking-details">
<div class="row">
<span class="label">Device ID:</span>
<span class="value" id="deviceId">๋กœ๋”ฉ ์ค‘...</span>
</div>
<div class="row">
<span class="label">์ถ”์  ์„œ๋ฒ„:</span>
<span class="value">seawolf2357-ev-cook-siteurl.static.hf.space</span>
</div>
<div class="row">
<span class="label">์‚ฌ์ดํŠธ ID:</span>
<span class="value">c4562ca1</span>
</div>
<div class="row">
<span class="label">์ถ”์  ์‹œ์ž‘:</span>
<span class="value" id="trackingStart">-</span>
</div>
<div class="row">
<span class="label">์ „์†ก ์ƒํƒœ:</span>
<span class="value" id="trackingStatus">๋Œ€๊ธฐ ์ค‘...</span>
</div>
</div>
</div>
<div class="buttons">
<button onclick="testTracking()">๐Ÿ“Š ์ถ”์  ํ…Œ์ŠคํŠธ</button>
<button onclick="sendCustomEvent()">๐ŸŽฏ ์ปค์Šคํ…€ ์ด๋ฒคํŠธ</button>
<button onclick="viewDetails()" class="secondary">๐Ÿ“‹ ์ƒ์„ธ ์ •๋ณด</button>
<button onclick="toggleDebug()" class="secondary">๐Ÿ› ๋””๋ฒ„๊ทธ ํŒจ๋„</button>
</div>
</section>
<div class="debug-panel" id="debugPanel">
<h3>๐Ÿ› ๋””๋ฒ„๊ทธ ๋กœ๊ทธ</h3>
<div class="debug-log" id="debugLog"></div>
<div class="buttons" style="margin-top: 10px;">
<button onclick="clearDebugLog()" class="secondary">๋กœ๊ทธ ์ง€์šฐ๊ธฐ</button>
<button onclick="checkServerStatus()" class="secondary">์„œ๋ฒ„ ์ƒํƒœ ํ™•์ธ</button>
</div>
</div>
<div class="info-grid">
<div class="info-card">
<h3>๐Ÿš€ ์‹ค์‹œ๊ฐ„ ์ถ”์ </h3>
<p>ํŽ˜์ด์ง€ ๋ฐฉ๋ฌธ, ํด๋ฆญ, ์Šคํฌ๋กค ๋“ฑ ๋ชจ๋“  ์‚ฌ์šฉ์ž ํ™œ๋™์ด ์‹ค์‹œ๊ฐ„์œผ๋กœ ์ถ”์ ๋ฉ๋‹ˆ๋‹ค. ๊ฐœ๋ฐœ์ž ๋„๊ตฌ ์ฝ˜์†”์—์„œ ์ถ”์  ๋กœ๊ทธ๋ฅผ ํ™•์ธํ•  ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.</p>
</div>
<div class="info-card">
<h3>๐Ÿ”’ ๊ฐœ์ธ์ •๋ณด ๋ณดํ˜ธ</h3>
<p>๋””๋ฐ”์ด์Šค ID๋Š” ๋ธŒ๋ผ์šฐ์ € ์ •๋ณด๋ฅผ ๊ธฐ๋ฐ˜์œผ๋กœ ์ƒ์„ฑ๋˜๋ฉฐ, ๊ฐœ์ธ์„ ์‹๋ณ„ํ•  ์ˆ˜ ์žˆ๋Š” ์ •๋ณด๋Š” ์ˆ˜์ง‘ํ•˜์ง€ ์•Š์Šต๋‹ˆ๋‹ค.</p>
</div>
<div class="info-card">
<h3>๐Ÿ“ˆ ๋ถ„์„ ๋Œ€์‹œ๋ณด๋“œ</h3>
<p>์ˆ˜์ง‘๋œ ๋ฐ์ดํ„ฐ๋Š” ์ถ”์  ์„œ๋ฒ„์˜ ๋Œ€์‹œ๋ณด๋“œ์—์„œ ์‹ค์‹œ๊ฐ„์œผ๋กœ ํ™•์ธํ•  ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.</p>
</div>
</div>
<div class="console-hint">
๐Ÿ’ก <strong>๊ฐœ๋ฐœ์ž ๋„๊ตฌ ํ™œ์šฉ:</strong> <code>F12</code>๋ฅผ ๋ˆŒ๋Ÿฌ Console ํƒญ์—์„œ ์ถ”์  ์ด๋ฒคํŠธ๋ฅผ ์‹ค์‹œ๊ฐ„์œผ๋กœ ํ™•์ธํ•˜์„ธ์š”!
</div>
<div id="detailsSection" style="display: none;">
<section class="hero-section" style="margin-top: 40px;">
<h2>๐Ÿ“Š ๋ธŒ๋ผ์šฐ์ € ์ƒ์„ธ ์ •๋ณด</h2>
<pre id="browserDetails" style="text-align: left; background: #f5f5f5; padding: 20px; border-radius: 8px; overflow-x: auto;"></pre>
</section>
</div>
</div>
<footer class="footer">
<p>&copy; 2025 EV Cook. ๋ชจ๋“  ๊ถŒ๋ฆฌ ๋ณด์œ .</p>
<p>์ถ”์  ์„œ๋ฒ„: <a href="https://seawolf2357-ev-cook-siteurl.static.hf.space" target="_blank" style="color: white;">seawolf2357-ev-cook-siteurl.static.hf.space</a></p>
</footer>
<!-- Visitor Tracking Script -->
<script>
(function() {
// ์ถ”์  ์„œ๋ฒ„ URL
const TRACKING_SERVER = 'https://seawolf2357-ev-cook-siteurl.static.hf.space/';
const SITE_ID = 'c4562ca1';
// ๋””๋ฐ”์ด์Šค ID ์ƒ์„ฑ/์กฐํšŒ
function getDeviceId() {
let deviceId = localStorage.getItem('_tracker_device_id');
if (!deviceId) {
deviceId = 'DEV_' + Date.now() + '_' + Math.random().toString(36).substring(2, 9);
localStorage.setItem('_tracker_device_id', deviceId);
}
return deviceId;
}
// ์ถ”์  ๋ฐ์ดํ„ฐ ์ „์†ก
async function collectAndSend(eventType = 'pageview', eventData = {}) {
const data = {
siteId: SITE_ID,
deviceId: getDeviceId(),
eventType: eventType,
eventData: eventData,
pageUrl: window.location.href,
pageTitle: document.title,
referrer: document.referrer,
userAgent: navigator.userAgent,
screenResolution: screen.width + 'x' + screen.height,
platform: navigator.platform,
language: navigator.language,
timestamp: new Date().toISOString()
};
try {
const response = await fetch(TRACKING_SERVER + '/call/process_tracking', {
method: 'POST',
headers: { 'Content-Type': 'application/json' },
body: JSON.stringify({ data: [JSON.stringify(data)] })
});
if (response.ok) {
const result = await response.json();
if (result.event_id) {
console.log('[Tracker] โœ… Event tracked');
updateTrackingStatus('์ „์†ก ์™„๋ฃŒ');
addDebugLog('success', `์ด๋ฒคํŠธ ์ „์†ก ์„ฑ๊ณต: ${eventType}`);
}
} else {
console.error('[Tracker] Server error:', response.status);
updateTrackingStatus('์ „์†ก ์‹คํŒจ');
addDebugLog('error', `์„œ๋ฒ„ ์˜ค๋ฅ˜: ${response.status}`);
}
} catch(e) {
console.error('[Tracker] Error:', e);
updateTrackingStatus('๋„คํŠธ์›Œํฌ ์˜ค๋ฅ˜');
addDebugLog('error', `๋„คํŠธ์›Œํฌ ์˜ค๋ฅ˜: ${e.message}`);
}
}
// ์ „์—ญ ์ถ”์  ํ•จ์ˆ˜
window._tracker = {
trackEvent: function(eventName, eventData) {
collectAndSend('custom', { name: eventName, data: eventData });
}
};
// ํŽ˜์ด์ง€ ๋กœ๋“œ์‹œ ์ถ”์ 
if (document.readyState === 'loading') {
document.addEventListener('DOMContentLoaded', () => collectAndSend());
} else {
collectAndSend();
}
// ๋””๋ฒ„๊ทธ ๋กœ๊ทธ (UI ์—ฐ๋™์šฉ)
const debugLog = [];
function addDebugLog(type, message) {
const timestamp = new Date().toLocaleTimeString();
debugLog.push({ type, message, timestamp });
updateDebugPanel();
}
function updateDebugPanel() {
const debugLogEl = document.getElementById('debugLog');
if (debugLogEl) {
debugLogEl.innerHTML = debugLog.slice(-50).reverse().map(entry =>
`<div class="log-entry ${entry.type}">[${entry.timestamp}] ${entry.message}</div>`
).join('');
}
}
function updateTrackingStatus(status) {
const statusEl = document.getElementById('trackingStatus');
if (statusEl) {
statusEl.textContent = status;
}
}
// ์ „์—ญ ํ•จ์ˆ˜ ํ™•์žฅ
window._tracker.getDebugLog = function() {
return debugLog;
};
// ์ดˆ๊ธฐํ™” ๋กœ๊ทธ
console.log('๐Ÿ” EV Cook Tracker ์ดˆ๊ธฐํ™”๋จ');
console.log('์„œ๋ฒ„:', TRACKING_SERVER);
console.log('์‚ฌ์ดํŠธ ID:', SITE_ID);
console.log('๋””๋ฐ”์ด์Šค ID:', getDeviceId());
addDebugLog('info', 'EV Cook Tracker ์ดˆ๊ธฐํ™” ์™„๋ฃŒ');
})();
</script>
<!-- End Visitor Tracking Script -->
<!-- ํŽ˜์ด์ง€ ๊ธฐ๋Šฅ ์Šคํฌ๋ฆฝํŠธ -->
<script>
// ํŽ˜์ด์ง€ ๋กœ๋“œ์‹œ ์‹คํ–‰
window.addEventListener('DOMContentLoaded', () => {
// Device ID ํ‘œ์‹œ
setTimeout(() => {
const deviceId = localStorage.getItem('_tracker_device_id');
if (deviceId) {
document.getElementById('deviceId').textContent = deviceId;
}
document.getElementById('trackingStart').textContent = new Date().toLocaleString('ko-KR');
}, 500);
});
// ์ถ”์  ํ…Œ์ŠคํŠธ
function testTracking() {
if (window._tracker) {
window._tracker.trackEvent('test_button_click', {
button: 'tracking_test',
timestamp: Date.now(),
location: 'hero_section',
userAction: true
});
alert('โœ… ์ถ”์  ์ด๋ฒคํŠธ๊ฐ€ ์ „์†ก๋˜์—ˆ์Šต๋‹ˆ๋‹ค!\n\n์ฝ˜์†”๊ณผ ๋””๋ฒ„๊ทธ ํŒจ๋„์—์„œ ํ™•์ธํ•˜์„ธ์š”.');
} else {
alert('โŒ ์ถ”์  ์Šคํฌ๋ฆฝํŠธ๊ฐ€ ๋กœ๋“œ๋˜์ง€ ์•Š์•˜์Šต๋‹ˆ๋‹ค.');
}
}
// ์ปค์Šคํ…€ ์ด๋ฒคํŠธ ์ „์†ก
function sendCustomEvent() {
const eventName = prompt('์ด๋ฒคํŠธ ์ด๋ฆ„์„ ์ž…๋ ฅํ•˜์„ธ์š”:', 'custom_action');
if (eventName && window._tracker) {
const eventData = {
custom_name: eventName,
user_input: true,
timestamp: Date.now(),
metadata: {
viewport: {
width: window.innerWidth,
height: window.innerHeight
},
scroll: {
x: window.scrollX,
y: window.scrollY
}
}
};
window._tracker.trackEvent(eventName, eventData);
alert(`โœ… '${eventName}' ์ด๋ฒคํŠธ๊ฐ€ ์ „์†ก๋˜์—ˆ์Šต๋‹ˆ๋‹ค!`);
console.log('[Custom Event]', eventName, eventData);
}
}
// ์ƒ์„ธ ์ •๋ณด ๋ณด๊ธฐ
function viewDetails() {
const details = {
tracking: {
deviceId: localStorage.getItem('_tracker_device_id'),
siteId: 'c4562ca1',
serverUrl: 'https://seawolf2357-ev-cook-siteurl.static.hf.space',
startTime: new Date().toLocaleString()
},
browser: {
userAgent: navigator.userAgent,
platform: navigator.platform,
vendor: navigator.vendor,
language: navigator.language,
languages: navigator.languages,
cookieEnabled: navigator.cookieEnabled,
doNotTrack: navigator.doNotTrack,
onLine: navigator.onLine,
plugins: navigator.plugins.length
},
screen: {
resolution: screen.width + 'x' + screen.height,
availableResolution: screen.availWidth + 'x' + screen.availHeight,
colorDepth: screen.colorDepth,
pixelRatio: window.devicePixelRatio,
orientation: screen.orientation ? screen.orientation.type : 'Unknown'
},
viewport: {
width: window.innerWidth,
height: window.innerHeight,
scrollX: window.scrollX,
scrollY: window.scrollY
},
hardware: {
cpuCores: navigator.hardwareConcurrency || 'Unknown',
deviceMemory: navigator.deviceMemory ? navigator.deviceMemory + 'GB' : 'Unknown',
maxTouchPoints: navigator.maxTouchPoints || 0
},
location: {
href: window.location.href,
hostname: window.location.hostname,
protocol: window.location.protocol,
pathname: window.location.pathname,
search: window.location.search,
hash: window.location.hash
},
time: {
timezone: Intl.DateTimeFormat().resolvedOptions().timeZone,
offset: new Date().getTimezoneOffset(),
locale: new Date().toLocaleString()
},
storage: {
localStorage: typeof(Storage) !== "undefined",
sessionStorage: typeof(sessionStorage) !== "undefined",
indexedDB: 'indexedDB' in window,
cookies: navigator.cookieEnabled
}
};
document.getElementById('browserDetails').textContent = JSON.stringify(details, null, 2);
document.getElementById('detailsSection').style.display = 'block';
// ์ƒ์„ธ ์ •๋ณด ๋ณด๊ธฐ๋„ ์ถ”์ 
window._tracker.trackEvent('view_details', {
action: 'show_browser_info',
detailsViewed: Object.keys(details)
});
}
// ๋””๋ฒ„๊ทธ ํŒจ๋„ ํ† ๊ธ€
function toggleDebug() {
const panel = document.getElementById('debugPanel');
if (panel) {
panel.style.display = panel.style.display === 'none' ? 'block' : 'none';
if (panel.style.display === 'block') {
window._tracker.trackEvent('debug_panel_opened', { timestamp: Date.now() });
}
}
}
// ๋””๋ฒ„๊ทธ ๋กœ๊ทธ ์ง€์šฐ๊ธฐ
function clearDebugLog() {
if (window._tracker && window._tracker.getDebugLog) {
window._tracker.getDebugLog().length = 0;
const debugLogEl = document.getElementById('debugLog');
if (debugLogEl) {
debugLogEl.innerHTML = '<div class="log-entry info">๋กœ๊ทธ๊ฐ€ ์ง€์›Œ์กŒ์Šต๋‹ˆ๋‹ค.</div>';
}
}
}
// ์„œ๋ฒ„ ์ƒํƒœ ํ™•์ธ
async function checkServerStatus() {
try {
const response = await fetch('https://seawolf2357-ev-cook-siteurl.static.hf.space/');
if (response.ok) {
alert('โœ… ์„œ๋ฒ„๊ฐ€ ์ •์ƒ์ ์œผ๋กœ ์ž‘๋™ ์ค‘์ž…๋‹ˆ๋‹ค.');
} else {
alert('โš ๏ธ ์„œ๋ฒ„ ์‘๋‹ต ์ƒํƒœ: ' + response.status);
}
} catch (e) {
alert('โŒ ์„œ๋ฒ„์— ์—ฐ๊ฒฐํ•  ์ˆ˜ ์—†์Šต๋‹ˆ๋‹ค: ' + e.message);
}
}
// ์ฝ˜์†”์— ์ถ”์  ์ •๋ณด ์ถœ๋ ฅ
console.log('%c๐Ÿ” EV Cook ์ถ”์  ์‹œ์Šคํ…œ ํ™œ์„ฑํ™”๋จ', 'color: #4CAF50; font-size: 16px; font-weight: bold;');
console.log('%c์ถ”์  ์„œ๋ฒ„:', 'font-weight: bold;', 'https://seawolf2357-ev-cook-siteurl.static.hf.space');
console.log('%c์‚ฌ์ดํŠธ ID:', 'font-weight: bold;', 'c4562ca1');
console.log('%cDevice ID:', 'font-weight: bold;', localStorage.getItem('_tracker_device_id') || '์ƒ์„ฑ ์ค‘...');
console.log('\n%c๐Ÿ’ก Tip: ๋””๋ฒ„๊ทธ ํŒจ๋„ ๋ฒ„ํŠผ์„ ํด๋ฆญํ•˜์—ฌ ์‹ค์‹œ๊ฐ„ ์ถ”์  ๋กœ๊ทธ๋ฅผ ํ™•์ธํ•˜์„ธ์š”!', 'color: #666;');
</script>
</body>
</html>