You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: user_guide_src/source/incoming/controllers.rst
+9-8Lines changed: 9 additions & 8 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -187,7 +187,7 @@ controllers. You can extend this class in any new controller.
187
187
188
188
.. literalinclude:: controllers/020.php
189
189
190
-
Then save the file to your **app/Controllers/** directory.
190
+
Then save the file to your **app/Controllers** directory.
191
191
192
192
.. important:: The file must be called **Helloworld.php**, with a capital ``H``. When you use Auto Routing, Controller class names MUST start with an uppercase letter and ONLY the first character can be uppercase.
193
193
@@ -218,7 +218,7 @@ class so that it can inherit all its methods.
218
218
219
219
.. note::
220
220
The system will attempt to match the URI against Controllers by matching each segment against
221
-
folders/files in **app/Controllers/**, when a match wasn't found against defined routes.
221
+
folders/files in **app/Controllers**, when a match wasn't found against defined routes.
222
222
That's why your folders/files MUST start with a capital letter and the rest MUST be lowercase.
223
223
224
224
If you want another naming convention you need to manually define it using the
@@ -319,7 +319,7 @@ If you are building a large application you might want to hierarchically
319
319
organize or structure your controllers into sub-directories. CodeIgniter
320
320
permits you to do this.
321
321
322
-
Simply create sub-directories under the main **app/Controllers/**,
322
+
Simply create sub-directories under the main **app/Controllers**,
323
323
and place your controller classes within them.
324
324
325
325
.. important:: Folder names MUST start with an uppercase letter and ONLY the first character can be uppercase.
@@ -333,7 +333,8 @@ To call the above controller your URI will look something like this::
333
333
334
334
example.com/index.php/products/shoes/show/123
335
335
336
-
.. note:: You cannot have directories with the same name in **app/Controllers/** and **public/**.
336
+
.. note:: You cannot have directories with the same name in **app/Controllers**
337
+
and **public**.
337
338
This is because if there is a directory, the web server will search for it and
338
339
it will not be routed to CodeIgniter.
339
340
@@ -381,7 +382,7 @@ For security reasons be sure to declare any new utility methods as ``protected``
381
382
382
383
.. literalinclude:: controllers/008.php
383
384
384
-
Then save the file to your **app/Controllers/** directory.
385
+
Then save the file to your **app/Controllers** directory.
385
386
386
387
.. important:: The file must be called **Helloworld.php**, with a capital ``H``. When you use Auto Routing, Controller class names MUST start with an uppercase letter and ONLY the first character can be uppercase.
387
388
@@ -410,7 +411,7 @@ class so that it can inherit all its methods.
410
411
411
412
.. note::
412
413
The system will attempt to match the URI against Controllers by matching each segment against
413
-
folders/files in **app/Controllers/**, when a match wasn't found against defined routes.
414
+
folders/files in **app/Controllers**, when a match wasn't found against defined routes.
414
415
That's why your folders/files MUST start with a capital letter and the rest MUST be lowercase.
415
416
416
417
If you want another naming convention you need to manually define it using the
@@ -488,7 +489,7 @@ If you are building a large application you might want to hierarchically
488
489
organize or structure your controllers into sub-directories. CodeIgniter
489
490
permits you to do this.
490
491
491
-
Simply create sub-directories under the main **app/Controllers/**,
492
+
Simply create sub-directories under the main **app/Controllers**,
492
493
and place your controller classes within them.
493
494
494
495
.. important:: Folder names MUST start with an uppercase letter and ONLY the first character can be uppercase.
@@ -502,7 +503,7 @@ To call the above controller your URI will look something like this::
502
503
503
504
example.com/index.php/products/shoes/show/123
504
505
505
-
.. note:: You cannot have directories with the same name in **app/Controllers/** and **public/**.
506
+
.. note:: You cannot have directories with the same name in **app/Controllers** and **public/**.
506
507
This is because if there is a directory, the web server will search for it and
0 commit comments