[IMP] Add language management for theme tuxlite_tbs

This commit is contained in:
Sylvain GARANCHER
2013-08-28 04:07:40 +02:00
parent 0efd36473c
commit 21588b23fa
3 changed files with 16 additions and 2 deletions

View File

@@ -1,5 +1,5 @@
<!DOCTYPE html> <!DOCTYPE html>
<html lang="en"> <html lang="{{ DEFAULT_LANG }}">
<head> <head>
<meta charset="utf-8"> <meta charset="utf-8">
<title>{% block windowtitle %}{{ SITENAME }}{% endblock %}</title> <title>{% block windowtitle %}{{ SITENAME }}{% endblock %}</title>

View File

@@ -2,6 +2,12 @@
{% if article.author %} {% if article.author %}
by <a class="url fn" href="{{ SITEURL }}/{{ article.author.url }}">{{ article.author }}</a> by <a class="url fn" href="{{ SITEURL }}/{{ article.author.url }}">{{ article.author }}</a>
{% if article.translations %}
<a href="{{ SITEURL }}/{{ article.url }}" class="btn btn-info xsmall">{{ article.lang or DEFAULT_LANG }}</a>
{% for translation in article.translations %}
<a href="{{ SITEURL }}/{{ translation.url }}" class="btn btn-info xsmall">{{ translation.lang }}</a>&nbsp;
{% endfor %}
{% endif %}
{% endif %} {% endif %}
{# Filed under <a href="{{ SITEURL }}/{{ article.category.url }}">{{ article.category }}</a> #} {# Filed under <a href="{{ SITEURL }}/{{ article.category.url }}">{{ article.category }}</a> #}

View File

@@ -2,7 +2,15 @@
{% block title %} {% endblock %} {% block title %} {% endblock %}
{% block content %} {% block content %}
<section id="content" class="body"> <section id="content" class="body">
<h2 class="content-title">{{ page.title }}</h2> <h2 class="content-title">
{{ page.title }}
{% if page.translations %}
<a href="{{ SITEURL }}/{{ page.url }}" class="btn btn-info xsmall">{{ page.lang or DEFAULT_LANG }}</a>
{% for translation in page.translations %}
<a href="{{ SITEURL }}/{{ translation.url }}" class="btn btn-info xsmall">{{ translation.lang }}</a>&nbsp;
{% endfor %}
{% endif %}
</h2>
{% if PDF_PROCESSOR %}<a href="{{ SITEURL }}/pdf/{{ page.slug }}.pdf">get {% if PDF_PROCESSOR %}<a href="{{ SITEURL }}/pdf/{{ page.slug }}.pdf">get
the pdf</a>{% endif %} the pdf</a>{% endif %}
{{ page.content }} {{ page.content }}