3 // @author Matt Todd <matt@matttoddphoto.com>
5 // @desc The routing patterns to match the request against to set the appropriate request variables
7 // setup date routes for searching times
8 Router2
::map(':year/:month/:day',
9 array('controller'=>'archive', 'action'=>'timespan'),
10 array('year'=>'year', 'month'=>'month', 'day'=>'day'));
11 Router2
::map(':year/:month',
12 array('controller'=>'archive', 'action'=>'timespan'),
13 array('year'=>'year', 'month'=>'month'));
15 array('controller'=>'archive', 'action'=>'timespan'),
16 array('year'=>'year'));
18 // map multiple tags to the blog/tags controller/action
19 Router2
::map('tags/:tags*', array('controller'=>'blog', 'action'=>'tags'));
21 // flexi-generic route (for show/:id or maybe comment/:id, etc)
22 Router2
::map(':action/:id', array('controller'=>'blog'));
24 // flexi-generic route (for :controller/:action/:id)
25 Router2
::map(':controller/:action/:id');
27 // flexi-generic route (for show/:id or maybe comment/:id, etc)
28 Router2
::map(':action/comment/:id/from/post/:post_id', array('controller'=>'comments'));
30 // default to the blog/index controller/action
31 Router2
::map('', array('controller'=>'blog', 'action'=>'index'));