diff options
Diffstat (limited to 'application/config/routes.php')
-rw-r--r-- | application/config/routes.php | 28 |
1 files changed, 18 insertions, 10 deletions
diff --git a/application/config/routes.php b/application/config/routes.php index f44f283f0..896d9d63f 100644 --- a/application/config/routes.php +++ b/application/config/routes.php @@ -1,4 +1,6 @@ -<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed'); +<?php +defined('BASEPATH') OR exit('No direct script access allowed'); + /* | ------------------------------------------------------------------------- | URI ROUTING @@ -17,13 +19,13 @@ | | Please see the user guide for complete details: | -| http://codeigniter.com/user_guide/general/routing.html +| https://codeigniter.com/user_guide/general/routing.html | | ------------------------------------------------------------------------- | RESERVED ROUTES | ------------------------------------------------------------------------- | -| There area two reserved routes: +| There are three reserved routes: | | $route['default_controller'] = 'welcome'; | @@ -33,11 +35,20 @@ | | $route['404_override'] = 'errors/page_missing'; | -| This route will tell the Router what URI segments to use if those provided -| in the URL cannot be matched to a valid route. +| This route will tell the Router which controller/method to use if those +| provided in the URL cannot be matched to a valid route. +| +| $route['translate_uri_dashes'] = FALSE; +| +| This is not exactly a route, but allows you to automatically route +| controller and method names that contain dashes. '-' isn't a valid +| class or method name character, so it requires translation. +| When you set this option to TRUE, it will replace ALL dashes in the +| controller and method URI segments. | +| Examples: my-controller/index -> my_controller/index +| my-controller/my-method -> my_controller/my_method */ - $route['default_controller'] = "file/file_default"; $route['user/(:any)'] = "user/$1"; $route['file/multipaste/(:any)'] = "file/multipaste/$1"; @@ -46,7 +57,4 @@ $route['tools/(:any)'] = "tools/$1"; $route['api/(:any)'] = "api/route/$1"; $route['(:any)'] = "file/file_default/index/$1"; $route['404_override'] = ''; - - -/* End of file routes.php */ -/* Location: ./application/config/routes.php */
\ No newline at end of file +$route['translate_uri_dashes'] = FALSE; |