Skip to content

Commit

Permalink
Add new syntax to minimal routing.
Browse files Browse the repository at this point in the history
Update error document loading to properly include both the version with and without id.

--HG--
branch : trunk
  • Loading branch information
bbangert committed Jul 22, 2008
1 parent 149a4ea commit 95c5d1b
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ def make_map():

# The ErrorController route (handles 404/500 error pages); it should
# likely stay at the top, ensuring it can always be resolved
map.connect('/error/{action}', controller='error')
map.connect('/error/{action}/{id}', controller='error')

# CUSTOM ROUTES HERE
Expand Down
4 changes: 2 additions & 2 deletions pylons/templates/minimal_project/+package+/routing.py_tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,6 @@ def make_map():

# CUSTOM ROUTES HERE

map.connect('/:controller/:action')
map.connect('/:controller/:action/:id')
map.connect('/{controller}/{action}')
map.connect('/{controller}/{action}/{id}')
return map

0 comments on commit 95c5d1b

Please sign in to comment.