soundbirder/public/javascripts/lang.js
2024-01-17 12:13:08 +01:00

6 lines
290 B
JavaScript
Executable File

let languageSelectorButton = document.getElementById('language-selector-button');
let languageSelector = document.getElementById('language-selector');
languageSelectorButton.addEventListener('click', function () {
let code = languageSelector.value;
window.location = '/' + code;
});