Bin will be removed on June 1, 2014 in favor of http://gist.github.com. Please save all your pastes before then. So long, and thanks for all the fish!×
1
2
3
4
5
6
7
8
9
10
Router::connect('/pastes/new/*', array('controller' => 'pastes', 'action' => 'add'));
Router::connect('/', array('controller' => 'pastes', 'action' => 'add'));
Router::connect('/pastes', array('controller' => 'pastes', 'action' => 'index'));
Router::connect('/pastes/view/:slug', array('controller' => 'pastes', 'action' => 'view'));
Router::connect('/pastes/author/:author', array('controller' => 'pastes', 'action' => 'index'));
Router::connect('/pastes/:year/:month/:day',
    array('controller' => 'pastes', 'action' => 'index', 'month' => null, 'day' => null),
    array('year' => '[12][0-9]{3}', 'month' => '(0[1-9]|1[012])', 'day' => '(0[1-9]|[12][0-9]|3[01])')
);