diff --git a/README.md b/README.md
index b04da5261d..690adacd60 100644
--- a/README.md
+++ b/README.md
@@ -172,7 +172,7 @@ Stirling PDF currently supports 26!
- Hindi (हिंदी) (hi_IN)
- Hungarian (Magyar) (hu_HU)
- Bulgarian (Български) (bg_BG)
-- Sebian Latin alphabet (Srpski) (sr-Latn-RS)
+- Sebian Latin alphabet (Srpski) (sr_LATN_RS)
## Contributing (creating issues, translations, fixing bugs, etc.)
diff --git a/src/main/resources/messages_sr-Latn-RS.properties b/src/main/resources/messages_sr_LATN_RS.properties
similarity index 100%
rename from src/main/resources/messages_sr-Latn-RS.properties
rename to src/main/resources/messages_sr_LATN_RS.properties
diff --git a/src/main/resources/static/js/languageSelection.js b/src/main/resources/static/js/languageSelection.js
index af67da487e..413bebe066 100644
--- a/src/main/resources/static/js/languageSelection.js
+++ b/src/main/resources/static/js/languageSelection.js
@@ -26,7 +26,7 @@ document.addEventListener("DOMContentLoaded", function () {
});
function setLanguageForDropdown(dropdownClass) {
- const defaultLocale = document.documentElement.lang || "en_GB";
+ const defaultLocale = document.documentElement.language || "en_GB";
const storedLocale = localStorage.getItem("languageCode") || defaultLocale;
const dropdownItems = document.querySelectorAll(dropdownClass);
diff --git a/src/main/resources/templates/about.html b/src/main/resources/templates/about.html
index 17e79d57d1..957bf45f4d 100644
--- a/src/main/resources/templates/about.html
+++ b/src/main/resources/templates/about.html
@@ -1,5 +1,5 @@
-
+
diff --git a/src/main/resources/templates/account.html b/src/main/resources/templates/account.html
index 9b7f4df97e..4398891dc7 100644
--- a/src/main/resources/templates/account.html
+++ b/src/main/resources/templates/account.html
@@ -1,5 +1,5 @@
-
+
diff --git a/src/main/resources/templates/addUsers.html b/src/main/resources/templates/addUsers.html
index 0cf3306d6b..f5e5e87d80 100644
--- a/src/main/resources/templates/addUsers.html
+++ b/src/main/resources/templates/addUsers.html
@@ -1,5 +1,5 @@
-
+
diff --git a/src/main/resources/templates/auto-split-pdf.html b/src/main/resources/templates/auto-split-pdf.html
index e4d213d81e..26106b46eb 100644
--- a/src/main/resources/templates/auto-split-pdf.html
+++ b/src/main/resources/templates/auto-split-pdf.html
@@ -1,5 +1,5 @@
-
+
diff --git a/src/main/resources/templates/change-creds.html b/src/main/resources/templates/change-creds.html
index 4709e40bde..b22a9bd26d 100644
--- a/src/main/resources/templates/change-creds.html
+++ b/src/main/resources/templates/change-creds.html
@@ -1,5 +1,5 @@
-
+
diff --git a/src/main/resources/templates/convert/book-to-pdf.html b/src/main/resources/templates/convert/book-to-pdf.html
index 94229ccfc2..7d9d436c7c 100644
--- a/src/main/resources/templates/convert/book-to-pdf.html
+++ b/src/main/resources/templates/convert/book-to-pdf.html
@@ -1,5 +1,5 @@
-
+
diff --git a/src/main/resources/templates/convert/file-to-pdf.html b/src/main/resources/templates/convert/file-to-pdf.html
index 3949688f08..26217b5676 100644
--- a/src/main/resources/templates/convert/file-to-pdf.html
+++ b/src/main/resources/templates/convert/file-to-pdf.html
@@ -1,5 +1,5 @@
-
+
diff --git a/src/main/resources/templates/convert/html-to-pdf.html b/src/main/resources/templates/convert/html-to-pdf.html
index 1118460638..c9a26a6bd5 100644
--- a/src/main/resources/templates/convert/html-to-pdf.html
+++ b/src/main/resources/templates/convert/html-to-pdf.html
@@ -1,5 +1,5 @@
-
+
diff --git a/src/main/resources/templates/convert/img-to-pdf.html b/src/main/resources/templates/convert/img-to-pdf.html
index 4de9e0f605..6d68fdecaa 100644
--- a/src/main/resources/templates/convert/img-to-pdf.html
+++ b/src/main/resources/templates/convert/img-to-pdf.html
@@ -1,5 +1,5 @@
-
+
diff --git a/src/main/resources/templates/convert/markdown-to-pdf.html b/src/main/resources/templates/convert/markdown-to-pdf.html
index d0266aac4d..8df3ad175e 100644
--- a/src/main/resources/templates/convert/markdown-to-pdf.html
+++ b/src/main/resources/templates/convert/markdown-to-pdf.html
@@ -1,5 +1,5 @@
-
+
diff --git a/src/main/resources/templates/convert/pdf-to-book.html b/src/main/resources/templates/convert/pdf-to-book.html
index e8ef940292..2056c7f567 100644
--- a/src/main/resources/templates/convert/pdf-to-book.html
+++ b/src/main/resources/templates/convert/pdf-to-book.html
@@ -1,5 +1,5 @@
-
+
diff --git a/src/main/resources/templates/convert/pdf-to-csv.html b/src/main/resources/templates/convert/pdf-to-csv.html
index d21156f08d..16da051ec2 100644
--- a/src/main/resources/templates/convert/pdf-to-csv.html
+++ b/src/main/resources/templates/convert/pdf-to-csv.html
@@ -1,5 +1,5 @@
-
+
diff --git a/src/main/resources/templates/convert/pdf-to-html.html b/src/main/resources/templates/convert/pdf-to-html.html
index b2347f0249..f2e914f98f 100644
--- a/src/main/resources/templates/convert/pdf-to-html.html
+++ b/src/main/resources/templates/convert/pdf-to-html.html
@@ -1,5 +1,5 @@
-
+
diff --git a/src/main/resources/templates/convert/pdf-to-img.html b/src/main/resources/templates/convert/pdf-to-img.html
index 610345785a..bcf3e8b39e 100644
--- a/src/main/resources/templates/convert/pdf-to-img.html
+++ b/src/main/resources/templates/convert/pdf-to-img.html
@@ -1,5 +1,5 @@
-
+
diff --git a/src/main/resources/templates/convert/pdf-to-pdfa.html b/src/main/resources/templates/convert/pdf-to-pdfa.html
index 1b75a07857..866449f139 100644
--- a/src/main/resources/templates/convert/pdf-to-pdfa.html
+++ b/src/main/resources/templates/convert/pdf-to-pdfa.html
@@ -1,5 +1,5 @@
-
+
diff --git a/src/main/resources/templates/convert/pdf-to-presentation.html b/src/main/resources/templates/convert/pdf-to-presentation.html
index f0a4a44a96..408ff1517f 100644
--- a/src/main/resources/templates/convert/pdf-to-presentation.html
+++ b/src/main/resources/templates/convert/pdf-to-presentation.html
@@ -1,5 +1,5 @@
-
+
diff --git a/src/main/resources/templates/convert/pdf-to-text.html b/src/main/resources/templates/convert/pdf-to-text.html
index cc6b7dcbf6..d161658986 100644
--- a/src/main/resources/templates/convert/pdf-to-text.html
+++ b/src/main/resources/templates/convert/pdf-to-text.html
@@ -1,5 +1,5 @@
-
+
diff --git a/src/main/resources/templates/convert/pdf-to-word.html b/src/main/resources/templates/convert/pdf-to-word.html
index 74e6f314be..6fd76f4e6e 100644
--- a/src/main/resources/templates/convert/pdf-to-word.html
+++ b/src/main/resources/templates/convert/pdf-to-word.html
@@ -1,5 +1,5 @@
-
+
diff --git a/src/main/resources/templates/convert/pdf-to-xml.html b/src/main/resources/templates/convert/pdf-to-xml.html
index 701220c17e..a7d020b0e9 100644
--- a/src/main/resources/templates/convert/pdf-to-xml.html
+++ b/src/main/resources/templates/convert/pdf-to-xml.html
@@ -1,5 +1,5 @@
-
+
diff --git a/src/main/resources/templates/convert/url-to-pdf.html b/src/main/resources/templates/convert/url-to-pdf.html
index 680443859c..94f0bfa56f 100644
--- a/src/main/resources/templates/convert/url-to-pdf.html
+++ b/src/main/resources/templates/convert/url-to-pdf.html
@@ -1,5 +1,5 @@
-
+
diff --git a/src/main/resources/templates/crop.html b/src/main/resources/templates/crop.html
index 825cfbec59..05de351617 100644
--- a/src/main/resources/templates/crop.html
+++ b/src/main/resources/templates/crop.html
@@ -1,5 +1,5 @@
-
+
diff --git a/src/main/resources/templates/error.html b/src/main/resources/templates/error.html
index d3cbecb6bf..954bcd7d15 100644
--- a/src/main/resources/templates/error.html
+++ b/src/main/resources/templates/error.html
@@ -1,5 +1,5 @@
-
+
diff --git a/src/main/resources/templates/extract-page.html b/src/main/resources/templates/extract-page.html
index a14e13d255..4bbd8b228e 100644
--- a/src/main/resources/templates/extract-page.html
+++ b/src/main/resources/templates/extract-page.html
@@ -1,5 +1,5 @@
-
+
diff --git a/src/main/resources/templates/fragments/languages.html b/src/main/resources/templates/fragments/languages.html
index f44caef354..07f16cc3dd 100644
--- a/src/main/resources/templates/fragments/languages.html
+++ b/src/main/resources/templates/fragments/languages.html
@@ -24,5 +24,5 @@
Ελληνικά
Hungarian
हिन्दी
-
Srpski
+
Srpski
diff --git a/src/main/resources/templates/fragments/navbar.html b/src/main/resources/templates/fragments/navbar.html
index c8ad96b66d..4eaa22eb80 100644
--- a/src/main/resources/templates/fragments/navbar.html
+++ b/src/main/resources/templates/fragments/navbar.html
@@ -139,7 +139,6 @@
-
diff --git a/src/main/resources/templates/home.html b/src/main/resources/templates/home.html
index 2d20dc3c7e..c03283a5dd 100644
--- a/src/main/resources/templates/home.html
+++ b/src/main/resources/templates/home.html
@@ -1,5 +1,5 @@
-
+
diff --git a/src/main/resources/templates/licenses.html b/src/main/resources/templates/licenses.html
index 8b8858c233..9d7cd2508f 100644
--- a/src/main/resources/templates/licenses.html
+++ b/src/main/resources/templates/licenses.html
@@ -1,5 +1,5 @@
-
+
diff --git a/src/main/resources/templates/login.html b/src/main/resources/templates/login.html
index 049c1740eb..1a900fd9cf 100644
--- a/src/main/resources/templates/login.html
+++ b/src/main/resources/templates/login.html
@@ -1,5 +1,5 @@
-
+
@@ -52,7 +52,7 @@
document.addEventListener('DOMContentLoaded', function() {
- const defaultLocale = document.documentElement.lang || 'en_GB';
+ const defaultLocale = document.documentElement.language || 'en_GB';
const storedLocale = localStorage.getItem('languageCode') || defaultLocale;
const currentURL = new URL(window.location.href);
@@ -113,7 +113,7 @@
if (languageCode) {
localStorage.setItem('languageCode', languageCode);
- const currentLang = document.documentElement.getAttribute('lang');
+ const currentLang = document.documentElement.getAttribute('language');
if (currentLang !== languageCode) {
console.log("currentLang", currentLang)
console.log("languageCode", languageCode)
diff --git a/src/main/resources/templates/merge-pdfs.html b/src/main/resources/templates/merge-pdfs.html
index 3638391e9c..33c0cb4f29 100644
--- a/src/main/resources/templates/merge-pdfs.html
+++ b/src/main/resources/templates/merge-pdfs.html
@@ -1,5 +1,5 @@
-
+
diff --git a/src/main/resources/templates/misc/add-image.html b/src/main/resources/templates/misc/add-image.html
index 1a0f96ee96..daa09a1b58 100644
--- a/src/main/resources/templates/misc/add-image.html
+++ b/src/main/resources/templates/misc/add-image.html
@@ -1,5 +1,5 @@
-
+
diff --git a/src/main/resources/templates/misc/add-page-numbers.html b/src/main/resources/templates/misc/add-page-numbers.html
index bd7104c266..07fc3f9e49 100644
--- a/src/main/resources/templates/misc/add-page-numbers.html
+++ b/src/main/resources/templates/misc/add-page-numbers.html
@@ -1,5 +1,5 @@
-
+