Update index.html
This commit is contained in:
+13
-3
@@ -16,12 +16,22 @@
|
|||||||
<script>
|
<script>
|
||||||
document.addEventListener('DOMContentLoaded', () => {
|
document.addEventListener('DOMContentLoaded', () => {
|
||||||
const userLang = navigator.language || navigator.userLanguage;
|
const userLang = navigator.language || navigator.userLanguage;
|
||||||
|
|
||||||
|
// İçeriği dil tercihine göre yükleme
|
||||||
if (userLang.startsWith('tr')) {
|
if (userLang.startsWith('tr')) {
|
||||||
window.location.replace('/hometr.html');
|
fetch('/hometr.html')
|
||||||
|
.then(response => response.text())
|
||||||
|
.then(html => {
|
||||||
|
document.documentElement.innerHTML = html; // Türkçe içeriği yükle
|
||||||
|
});
|
||||||
} else {
|
} else {
|
||||||
window.location.replace('/home.html');
|
fetch('/home.html')
|
||||||
|
.then(response => response.text())
|
||||||
|
.then(html => {
|
||||||
|
document.documentElement.innerHTML = html; // İngilizce içeriği yükle
|
||||||
|
});
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
const disabledKeys = ["c", "C", "x", "J", "u", "I"]; // keys that will be disabled
|
const disabledKeys = ["c", "C", "x", "J", "u", "I"]; // keys that will be disabled
|
||||||
const showAlert = e => {
|
const showAlert = e => {
|
||||||
|
|||||||
Reference in New Issue
Block a user