diff --git a/www.i2p2/app.py b/www.i2p2/app.py index f21b18b2..3002fa78 100644 --- a/www.i2p2/app.py +++ b/www.i2p2/app.py @@ -33,7 +33,7 @@ def app(environ, start_response): theme = req.cookies['style'] if 'theme' in req.args.keys(): theme = req.args['theme'] - if not theme in ['light', 'dark']: + if not os.path.isfile('static/styles/%s.css' % theme): theme = 'light' if path == '': path = 'index' diff --git a/www.i2p2/pages/_layout.html b/www.i2p2/pages/_layout.html index d1362a00..bcae26e2 100644 --- a/www.i2p2/pages/_layout.html +++ b/www.i2p2/pages/_layout.html @@ -5,11 +5,7 @@ {% filter capture('title') %}{% block title %}{% endblock %}{% endfilter %} - I2P - {% if theme == 'light' %} - - {% else %} - - {% endif %} + diff --git a/www.i2p2/pages/_layout_de.html b/www.i2p2/pages/_layout_de.html index 643cd0aa..3fc3726b 100644 --- a/www.i2p2/pages/_layout_de.html +++ b/www.i2p2/pages/_layout_de.html @@ -6,11 +6,7 @@ {% filter capture('title') %}{% block title %}{% endblock %}{% endfilter %} - I2P - {% if theme == 'light' %} - - {% else %} - - {% endif %} + diff --git a/www.i2p2/static/styles/default.css b/www.i2p2/static/styles/light.css similarity index 100% rename from www.i2p2/static/styles/default.css rename to www.i2p2/static/styles/light.css