diff options
Diffstat (limited to 'application')
-rw-r--r-- | application/config/routes.php | 14 | ||||
-rw-r--r-- | application/controllers/Welcome.php (renamed from application/controllers/welcome.php) | 2 | ||||
-rw-r--r-- | application/views/welcome_message.php | 2 |
3 files changed, 14 insertions, 4 deletions
diff --git a/application/config/routes.php b/application/config/routes.php index a5047a14e..3078c3c76 100644 --- a/application/config/routes.php +++ b/application/config/routes.php @@ -49,7 +49,7 @@ | RESERVED ROUTES | ------------------------------------------------------------------------- | -| There are two reserved routes: +| There are three reserved routes: | | $route['default_controller'] = 'welcome'; | @@ -62,10 +62,20 @@ | 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'] = 'welcome'; $route['404_override'] = ''; +$route['translate_uri_dashes'] = FALSE; /* End of file routes.php */ /* Location: ./application/config/routes.php */
\ No newline at end of file diff --git a/application/controllers/welcome.php b/application/controllers/Welcome.php index 2f0e358bc..31ceea948 100644 --- a/application/controllers/welcome.php +++ b/application/controllers/Welcome.php @@ -50,4 +50,4 @@ class Welcome extends CI_Controller { } /* End of file welcome.php */ -/* Location: ./application/controllers/welcome.php */
\ No newline at end of file +/* Location: ./application/controllers/Welcome.php */
\ No newline at end of file diff --git a/application/views/welcome_message.php b/application/views/welcome_message.php index 3cc8b80aa..2466a83fc 100644 --- a/application/views/welcome_message.php +++ b/application/views/welcome_message.php @@ -104,7 +104,7 @@ defined('BASEPATH') OR exit('No direct script access allowed'); <code>application/views/welcome_message.php</code> <p>The corresponding controller for this page is found at:</p> - <code>application/controllers/welcome.php</code> + <code>application/controllers/Welcome.php</code> <p>If you are exploring CodeIgniter for the very first time, you should start by reading the <a href="user_guide/">User Guide</a>.</p> </div> |