awips2/pythonPackages/Werkzeug-0.12.1/examples/i18nurls/urls.py

12 lines
348 B
Python
Raw Normal View History

2017-04-21 18:33:55 -06:00
from werkzeug.routing import Map, Rule, Submount
map = Map([
Rule('/', endpoint='#language_select'),
Submount('/<string(length=2):lang_code>', [
Rule('/', endpoint='index'),
Rule('/about', endpoint='about'),
Rule('/blog/', endpoint='blog/index'),
Rule('/blog/<int:post_id>', endpoint='blog/show')
])
])