Merge branch 'set-lang-attribute' into 'master'

[ADD] Language code to page and language selector

See merge request allianceauth/allianceauth!1528
This commit is contained in:
Ariel Rin 2023-10-07 04:39:01 +00:00
commit 53ffd7f885
2 changed files with 2 additions and 2 deletions

View File

@ -5,7 +5,7 @@
<select onchange="this.form.submit()" class="form-control" id="lang-select" name="language">
{% get_language_info_list for LANGUAGES as languages %}
{% for language in languages %}
<option value="{{ language.code }}"{% if language.code == LANGUAGE_CODE %} selected="selected"{% endif %}>
<option lang="{{ language.code }}" value="{{ language.code }}"{% if language.code == LANGUAGE_CODE %} selected="selected"{% endif %}>
{{ language.name_local|capfirst }} ({{ language.code }})
</option>
{% endfor %}

View File

@ -2,7 +2,7 @@
{% load navactive %}
{% load auth_notifications %}
<!DOCTYPE html>
<html lang="en">
<html lang="{{ LANGUAGE_CODE }}">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">