Files
SkyArtShop/website/admin/test-inline-logout.html

40 lines
1.2 KiB
HTML
Raw Permalink Normal View History

2025-12-19 20:44:46 -06:00
<!DOCTYPE html>
<html>
<head>
<title>Test Inline Logout</title>
2026-01-19 01:17:43 -06:00
<link rel="icon" type="image/png" href="/admin/favicon.png" />
2025-12-19 20:44:46 -06:00
<script src="/admin/js/auth.js"></script>
</head>
<body>
<h1>Testing inline onclick="logout()"</h1>
<button class="btn-logout" onclick="logout()">
Test Inline onclick Logout
</button>
<div id="result" style="margin-top: 20px; font-family: monospace;"></div>
<script>
const resultDiv = document.getElementById('result');
function log(msg) {
resultDiv.innerHTML += msg + '<br>';
console.log(msg);
}
window.addEventListener('load', function() {
log('Page loaded');
log('typeof logout: ' + typeof logout);
log('typeof window.logout: ' + typeof window.logout);
log('typeof window.showLogoutConfirm: ' + typeof window.showLogoutConfirm);
if (typeof logout === 'function') {
log('✅ logout() function exists at global scope');
} else {
log('❌ logout() function NOT found at global scope');
}
});
</script>
</body>
</html>