- map.connect '/', :controller => 'site', :action => 'index'
- map.connect '/edit', :controller => 'site', :action => 'edit'
- map.connect '/export', :controller => 'site', :action => 'export'
- map.connect '/login', :controller => 'user', :action => 'login'
- map.connect '/logout', :controller => 'user', :action => 'logout'
- map.connect '/offline', :controller => 'site', :action => 'offline'
- map.connect '/user/new', :controller => 'user', :action => 'new'
- map.connect '/user/save', :controller => 'user', :action => 'save'
- map.connect '/user/confirm', :controller => 'user', :action => 'confirm'
- map.connect '/user/go_public', :controller => 'user', :action => 'go_public'
- map.connect '/user/reset-password', :controller => 'user', :action => 'reset_password'
- map.connect '/user/upload-image', :controller => 'user', :action => 'upload_image'
- map.connect '/user/forgot-password', :controller => 'user', :action => 'lost_password'
-
- map.connect '/index.html', :controller => 'site', :action => 'index'
- map.connect '/edit.html', :controller => 'site', :action => 'edit'
- map.connect '/export.html', :controller => 'site', :action => 'export'
- map.connect '/search.html', :controller => 'way_tag', :action => 'search'
- map.connect '/login.html', :controller => 'user', :action => 'login'
- map.connect '/logout.html', :controller => 'user', :action => 'logout'
- map.connect '/create-account.html', :controller => 'user', :action => 'new'
- map.connect '/forgot-password.html', :controller => 'user', :action => 'lost_password'
-
- # traces
- map.connect '/traces', :controller => 'trace', :action => 'list'
- map.connect '/traces/page/:page', :controller => 'trace', :action => 'list'
- map.connect '/traces/rss', :controller => 'trace', :action => 'georss'
- map.connect '/traces/tag/:tag', :controller => 'trace', :action => 'list'
- map.connect '/traces/tag/:tag/page/:page', :controller => 'trace', :action => 'list'
- map.connect '/traces/tag/:tag/rss', :controller => 'trace', :action => 'georss'
- map.connect '/traces/mine', :controller => 'trace', :action => 'mine'
- map.connect '/traces/mine/page/:page', :controller => 'trace', :action => 'mine'
- map.connect '/traces/mine/tag/:tag', :controller => 'trace', :action => 'mine'
- map.connect '/traces/mine/tag/:tag/page/:page', :controller => 'trace', :action => 'mine'
- map.connect '/trace/create', :controller => 'trace', :action => 'create'
- map.connect '/trace/:id/data', :controller => 'trace', :action => 'data'
- map.connect '/trace/:id/data.:format', :controller => 'trace', :action => 'data'
- map.connect '/trace/:id/edit', :controller => 'trace', :action => 'edit'
- map.connect '/trace/:id/delete', :controller => 'trace', :action => 'delete'
- map.connect '/trace/:id/make_public', :controller => 'trace', :action => 'make_public'
- map.connect '/user/:display_name/traces', :controller => 'trace', :action => 'list'
- map.connect '/user/:display_name/traces/page/:page', :controller => 'trace', :action => 'list'
- map.connect '/user/:display_name/traces/rss', :controller => 'trace', :action => 'georss'
- map.connect '/user/:display_name/traces/tag/:tag', :controller => 'trace', :action => 'list'
- map.connect '/user/:display_name/traces/tag/:tag/page/:page', :controller => 'trace', :action => 'list'
- map.connect '/user/:display_name/traces/tag/:tag/rss', :controller => 'trace', :action => 'georss'
- map.connect '/user/:display_name/traces/:id', :controller => 'trace', :action => 'view'
- map.connect '/user/:display_name/traces/:id/picture', :controller => 'trace', :action => 'picture'
- map.connect '/user/:display_name/traces/:id/icon', :controller => 'trace', :action => 'icon'
+ # traces
+ match '/user/:display_name/traces/tag/:tag/page/:page' => 'trace#list'
+ match '/user/:display_name/traces/tag/:tag' => 'trace#list'
+ match '/user/:display_name/traces/page/:page' => 'trace#list'
+ match '/user/:display_name/traces' => 'trace#list'
+ match '/user/:display_name/traces/tag/:tag/rss' => 'trace#georss'
+ match '/user/:display_name/traces/rss' => 'trace#georss'
+ match '/user/:display_name/traces/:id' => 'trace#view'
+ match '/user/:display_name/traces/:id/picture' => 'trace#picture'
+ match '/user/:display_name/traces/:id/icon' => 'trace#icon'
+ match '/traces/tag/:tag/page/:page' => 'trace#list'
+ match '/traces/tag/:tag' => 'trace#list'
+ match '/traces/page/:page' => 'trace#list'
+ match '/traces' => 'trace#list'
+ match '/traces/tag/:tag/rss' => 'trace#georss'
+ match '/traces/rss' => 'trace#georss'
+ match '/traces/mine/tag/:tag/page/:page' => 'trace#mine'
+ match '/traces/mine/tag/:tag' => 'trace#mine'
+ match '/traces/mine/page/:page' => 'trace#mine'
+ match '/traces/mine' => 'trace#mine'
+ match '/trace/create' => 'trace#create'
+ match '/trace/:id/data' => 'trace#data'
+ match '/trace/:id/data.:format' => 'trace#data'
+ match '/trace/:id/edit' => 'trace#edit'
+ match '/trace/:id/delete' => 'trace#delete'
+
+ # diary pages
+ match '/diary/new' => 'diary_entry#new'
+ match '/diary/friends' => 'diary_entry#list', :friends => true
+ match '/diary/nearby' => 'diary_entry#list', :nearby => true
+ match '/user/:display_name/diary/rss' => 'diary_entry#rss', :format => :rss
+ match '/diary/:language/rss' => 'diary_entry#rss', :format => :rss
+ match '/diary/rss' => 'diary_entry#rss', :format => :rss
+ match '/user/:display_name/diary' => 'diary_entry#list'
+ match '/diary/:language' => 'diary_entry#list'
+ match '/diary' => 'diary_entry#list'
+ match '/user/:display_name/diary/:id' => 'diary_entry#view', :id => /\d+/
+ match '/user/:display_name/diary/:id/newcomment' => 'diary_entry#comment', :id => /\d+/
+ match '/user/:display_name/diary/:id/edit' => 'diary_entry#edit', :id => /\d+/
+ match '/user/:display_name/diary/:id/hide' => 'diary_entry#hide', :id => /\d+/
+ match '/user/:display_name/diary/:id/hidecomment/:comment' => 'diary_entry#hidecomment', :id => /\d+/, :comment => /\d+/