var language = { eng: { //nav homenav: "Home", aboutmenav: "About Me", projectsnav: "Projects", contactnav: "Contact me", //index.html welcometitle: "Hello Internet!", welcome1: "I'm Malik, some guy on the web who's learning to code.", welcome2: "Welcome to my personal website. Here you can find out more about me and my projects! Thanks for stopping by. :)", //aboutme.html aboutmetitle: "About me:", aboutme1: "Hey, even after almost two decades on this planet I don't know exactly what to write about myself in these 'About Me's. But I'll give it a try. :)", aboutme2: "So I'm very interested in everything to do with computers. I use Linux and am currently learning to program. Away from the computer, I like to meet up with friends and listen to a lot of music. Lately I've been listening mainly to techno lately, which is why I also go to techno clubs regularly. ", aboutme3: "Last but not least. I love cats and even have two of these weirdos.", aboutmebutton1: "Cats", aboutmebutton2: "Linux", aboutmebutton3: "Top 10 Techno", //projects.html projectstitle: "Comming Soon!", projects: "Nothing here yet. :)", //contactme.html contacttitle: "Contact", contact: "Email: malik.wachter[at]mawacode.de", //aboutme/cats.html catstitle: "My Cats!", cats: "The white cat is called Percy and the black and white cat is called Mailo.", //aboutme/linux.html linuxtitle: "Linux", linux1: "My Linux distrohop history:", linuxli1: "2021 January - Linux Mint", linuxli2: "2021 June - Kubuntu", linuxli3: "2021 July - KDE Neon", linuxli4: "2022 February - Fedora", linuxli5: "2022 June - Nobara", linuxli6: "Currently Fedora and Nobara", linux2: "Desktop: Nobara Linux", linux2_2: "Laptop: Fedora Linux", linux3: "Distros I've only played around with once:", linuxli7: "Arch Linux", linuxli8: "Artix Linux", linuxli9: "AntiX", linuxli10: "TailsOS", linux4: "Other Linux devices I own:", linuxli11: "Raspberry Pi - Rasberry Pi OS", linuxli12: "Steam Deck - SteamOS", linuxli13: "Fairphone 3+ - iodéOS", //aboutme/techno.html technotitle: "Techno Top 10", techno: "Befor you read: This top 10 list is not meant seriously. It was not rated according to any criteria. It's just a collection of songs that I currently enjoy listening to.", technoli1: "1. i wanna be your girlfriend | Dj Brice", technoli2: "2. DIE LIEBE KOMMT NICHT AUS BERLIN | Brutalismus 3000", technoli3: "3. HEISS (Floorkiller Flex) | ÅMRTÜM", technoli4: "4. Underground | Tucker", technoli5: "5. Audio Bully - Original | ANSBRO", technoli6: "6. Goes Crazy - Original Mix | RBX", technoli7: "7. As We Kick | RVLT, Ouija", technoli8: "8. Language Of The Devil | Infeed", technoli9: "9. NUR MEIN KÖRPER UND DIE ANGST | Brutalismus 3000", technoli10: "10. Atme Ein (Atme Rauch aus) | Butschi, Felix Jaehn, Fairy Mary" }, ger: { //nav homenav: "Startseite", aboutmenav: "Über Mich", projectsnav: "Projekte", contactnav: "Kontakt", //index.html welcometitle: "Hallo Internet!", welcome1: "Ich bin Malik, ein Typ aus dem Internet, der programmieren lernt.", welcome2: "Willkommen auf meiner persönlichen Website. Hier kannst du mehr über mich und meine Projekte erfahren! Danke fürs Vorbeischauen :)", //aboutme.html aboutmetitle: "Über mich:", aboutme1: "Hey, selbst nach fast zwei Jahrzehnten auf diesem Planeten weiß ich nicht genau, was ich in diesen 'Über mich's überhaupt schreiben soll. Aber ich werde es versuchen :)", aboutme2: "Ich interessiere mich also sehr für alles, was mit Computern zu tun hat. Ich benutze Linux und lerne gerade programmieren. Abseits des Computers treffe ich mich gerne mit Freunden und höre viel Musik. In letzter Zeit höre ich vor allem Techno, deshalb gehe ich auch regelmäßig in Techno-Clubs.", aboutme3: "Zu guter Letzt, Ich liebe Katzen und habe sogar zwei von diesen Spinnern.", aboutmebutton1: "Katzen", aboutmebutton2: "Linux", aboutmebutton3: "Top 10 Techno", //projects.html projectstitle: "Kommt bald!", projects: "Noch ist hier nichts :)", //contactme.html contacttitle: "Kontakt", contact: "Email: malik.wachter[at]mawacode.de", //aboutme/cats.html catstitle: "Meine Katzen!", cats: "Der weiße Kater heißt Percy und der schwarz-weiße Kater heißt Mailo.", //aboutme/linux.html linuxtitle: "Linux", linux1: "Meine Linux distrohop Geschichte:", linuxli1: "2021 Januar - Linux Mint", linuxli2: "2021 Juni - Kubuntu", linuxli3: "2021 Juli - KDE Neon", linuxli4: "2022 Februar - Fedora", linuxli5: "2022 Juni - Nobara", linuxli6: "Aktuell Fedora und Nobara", linux2: "Desktop: Nobara Linux", linux2_2: "Laptop: Fedora Linux", linux3: "Distros mit dennen ich nurmal rumgespielt habe:", linuxli7: "Arch Linux", linuxli8: "Artix Linux", linuxli9: "AntiX", linuxli10: "TailsOS", linux4: "Weitere Linux Geräte in meinem Besitz:", linuxli11: "Raspberry Pi - Rasberry Pi OS", linuxli12: "Steam Deck - SteamOS", linuxli13: "Fairphone 3+ - iodéOS", //aboutme/techno.html technotitle: "Techno Top 10", techno: "Vorab: Diese Top-10-Liste ist nicht ernst gemeint. Es wurde nach keinen Kriterien bewertet. Das ist nur eine Sammlung von Liedern, die ich aktuell gerne höre.", technoli1: "1. i wanna be your girlfriend | Dj Brice", technoli2: "2. DIE LIEBE KOMMT NICHT AUS BERLIN | Brutalismus 3000", technoli3: "3. HEISS (Floorkiller Flex) | ÅMRTÜM", technoli4: "4. Underground | Tucker", technoli5: "5. Audio Bully - Original | ANSBRO", technoli6: "6. Goes Crazy - Original Mix | RBX", technoli7: "7. As We Kick | RVLT, Ouija", technoli8: "8. Language Of The Devil | Infeed", technoli9: "9. NUR MEIN KÖRPER UND DIE ANGST | Brutalismus 3000", technoli10: "10. Atme Ein (Atme Rauch aus) | Butschi, Felix Jaehn, Fairy Mary" } }; var isGerman = localStorage.getItem("isGerman") === "true"; if(isGerman===true) { //nav homenav.textContent = language.ger.homenav; aboutmenav.textContent = language.ger.aboutmenav; projectsnav.textContent = language.ger.projectsnav; contactnav.textContent = language.ger.contactnav; //index.html if (window.location.pathname == '/' || window.location.href.indexOf("index") > -1) { welcometitle.textContent = language.ger.welcometitle; welcome1.textContent = language.ger.welcome1; welcome2.textContent = language.ger.welcome2; } //aboutme.html else if(window.location.href.indexOf("aboutme.html") > -1) { aboutmetitle.textContent = language.ger.aboutmetitle; aboutme1.textContent = language.ger.aboutme1; aboutme2.textContent = language.ger.aboutme2; aboutme3.textContent = language.ger.aboutme3; aboutmebutton1.textContent = language.ger.aboutmebutton1; aboutmebutton2.textContent = language.ger.aboutmebutton2; aboutmebutton3.textContent = language.ger.aboutmebutton3; } //projects.html else if(window.location.href.indexOf("projects") > -1) { projectstitle.textContent = language.ger.projectstitle; projects.textContent = language.ger.projects; } //contactme.html else if(window.location.href.indexOf("contactme") > -1) { contacttitle.textContent = language.ger.contacttitle; contact.textContent = language.ger.contact; } //aboutme/cats.html else if(window.location.href.indexOf("cats") > -1) { catstitle.textContent = language.ger.catstitle; cats.textContent = language.ger.cats; } //aboutme/linux.html else if(window.location.href.indexOf("linux") > -1) { linuxtitle.textContent = language.ger.linuxtitle; linux1.textContent = language.ger.linux1; linuxli1.textContent = language.ger.linuxli1; linuxli2.textContent = language.ger.linuxli2; linuxli3.textContent = language.ger.linuxli3; linuxli4.textContent = language.ger.linuxli4; linuxli5.textContent = language.ger.linuxli5; linuxli6.textContent = language.ger.linuxli6; linux2.textContent = language.ger.linux2; linux2_2.textContent = language.ger.linux2_2; linux3.textContent = language.ger.linux3; linuxli7.textContent = language.ger.linuxli7; linuxli8.textContent = language.ger.linuxli8; linuxli9.textContent = language.ger.linuxli9; linuxli10.textContent = language.ger.linuxli10; linux4.textContent = language.ger.linux4; linuxli11.textContent = language.ger.linuxli11; linuxli12.textContent = language.ger.linuxli12; linuxli13.textContent = language.ger.linuxli13; } //aboutme/techno.html else if(window.location.href.indexOf("techno") > -1) { technotitle.textContent = language.ger.technotitle; techno.textContent = language.ger.techno; technoli1.textContent = language.ger.technoli1; technoli2.textContent = language.ger.technoli2; technoli3.textContent = language.ger.technoli3; technoli4.textContent = language.ger.technoli4; technoli5.textContent = language.ger.technoli5; technoli6.textContent = language.ger.technoli6; technoli7.textContent = language.ger.technoli7; technoli8.textContent = language.ger.technoli8; technoli9.textContent = language.ger.technoli9; technoli10.textContent = language.ger.technoli10; } } else{ //nav homenav.textContent = language.eng.homenav; aboutmenav.textContent = language.eng.aboutmenav; projectsnav.textContent = language.eng.projectsnav; contactnav.textContent = language.eng.contactnav; //index.html if (window.location.pathname == '/' || window.location.href.indexOf("index") > -1) { welcometitle.textContent = language.eng.welcometitle; welcome1.textContent = language.eng.welcome1; welcome2.textContent = language.eng.welcome2; } //aboutme.html else if(window.location.href.indexOf("aboutme.html") > -1) { aboutmetitle.textContent = language.eng.aboutmetitle; aboutme1.textContent = language.eng.aboutme1; aboutme2.textContent = language.eng.aboutme2; aboutme3.textContent = language.eng.aboutme3; aboutmebutton1.textContent = language.eng.aboutmebutton1; aboutmebutton2.textContent = language.eng.aboutmebutton2; aboutmebutton3.textContent = language.eng.aboutmebutton3; } //projects.html else if(window.location.href.indexOf("projects") > -1) { projectstitle.textContent = language.eng.projectstitle; projects.textContent = language.eng.projects; } //contactme.html else if(window.location.href.indexOf("contactme") > -1) { contacttitle.textContent = language.eng.contacttitle; contact.textContent = language.eng.contact; } //aboutme/cats.html else if(window.location.href.indexOf("cats") > -1) { catstitle.textContent = language.eng.catstitle; cats.textContent = language.eng.cats; } //aboutme/linux.html else if(window.location.href.indexOf("linux") > -1) { linuxtitle.textContent = language.eng.linuxtitle; linux1.textContent = language.eng.linux1; linuxli1.textContent = language.eng.linuxli1; linuxli2.textContent = language.eng.linuxli2; linuxli3.textContent = language.eng.linuxli3; linuxli4.textContent = language.eng.linuxli4; linuxli5.textContent = language.eng.linuxli5; linuxli6.textContent = language.eng.linuxli6; linux2.textContent = language.eng.linux2; linux2_2.textContent = language.eng.linux2_2; linux3.textContent = language.eng.linux3; linuxli7.textContent = language.eng.linuxli7; linuxli8.textContent = language.eng.linuxli8; linuxli9.textContent = language.eng.linuxli9; linuxli10.textContent = language.eng.linuxli10; linux4.textContent = language.eng.linux4; linuxli11.textContent = language.eng.linuxli11; linuxli12.textContent = language.eng.linuxli12; linuxli13.textContent = language.eng.linuxli13; } //aboutme/techno.html else if(window.location.href.indexOf("techno") > -1) { technotitle.textContent = language.eng.technotitle; techno.textContent = language.eng.techno; technoli1.textContent = language.eng.technoli1; technoli2.textContent = language.eng.technoli2; technoli3.textContent = language.eng.technoli3; technoli4.textContent = language.eng.technoli4; technoli5.textContent = language.eng.technoli5; technoli6.textContent = language.eng.technoli6; technoli7.textContent = language.eng.technoli7; technoli8.textContent = language.eng.technoli8; technoli9.textContent = language.eng.technoli9; technoli10.textContent = language.eng.technoli10; } } function langChange() { isGerman = !isGerman; localStorage.setItem("isGerman", isGerman); console.log(localStorage.getItem("isGerman")); window.location.reload(); }