From caeae71203c18af6006812145b757af1057e3188 Mon Sep 17 00:00:00 2001 From: LUCASTUCIOUS-OnePlus Date: Mon, 6 Mar 2023 01:43:27 +0100 Subject: [PATCH] ChatGPT advice --- index.html | 9 ++++----- js/language.js | 11 ++++++----- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/index.html b/index.html index ecfb860..5ef5446 100644 --- a/index.html +++ b/index.html @@ -1,13 +1,12 @@ - - + - + fateforge-tools - + @@ -66,7 +65,7 @@ - + diff --git a/js/language.js b/js/language.js index ede6016..7baab8d 100644 --- a/js/language.js +++ b/js/language.js @@ -1,11 +1,12 @@ -// This code selects all elements in the HTML document with the "data-localize" attribute // and applies the jQuery "localize" function to them with the "main" localization file and a path prefix of "lang" +// this code localizes all elements with a "data-localize" attribute $("[data-localize]").localize("main", { pathPrefix: "lang" }); -// This is a function that changes the language to French by calling the "localize" function with a language code of "fr" -function changeLangFR() { $("[data-localize]").localize("main", { pathPrefix: "lang", language: "fr", }); -} +// You can also override the language detection and specify a language code. This code defines a function that sets the language to French. +function changeLangFR() { $("[data-localize]").localize("main", { pathPrefix: "lang", language: "fr", }); } -// This is a function that changes the language to English by calling the "localize" function with a language code of "en" + + +// This code defines a function that sets the language to English. function changeLangEN() { $("[data-localize]").localize("main", { pathPrefix: "lang",