summaryrefslogtreecommitdiffstats
path: root/user_guide_src/source/general
diff options
context:
space:
mode:
authorAndrey Andreev <narf@devilix.net>2018-06-12 15:46:16 +0200
committerAndrey Andreev <narf@devilix.net>2018-06-12 15:46:16 +0200
commitbb451aa0e4853f9afd4263769eeea1d9aad3a600 (patch)
treeaa3770006128ab46d570e6b6aad756e4e92299d9 /user_guide_src/source/general
parente76217041ddcae80f11b50b44a7d409b6722ad40 (diff)
parenta9da3dd2f16a8f97d7bc4ff5572b28e4bb84c813 (diff)
Merge branch '3.1-stable'
Diffstat (limited to 'user_guide_src/source/general')
-rw-r--r--user_guide_src/source/general/controllers.rst2
-rw-r--r--user_guide_src/source/general/core_classes.rst9
-rw-r--r--user_guide_src/source/general/creating_libraries.rst3
-rw-r--r--user_guide_src/source/general/models.rst14
-rw-r--r--user_guide_src/source/general/urls.rst4
5 files changed, 8 insertions, 24 deletions
diff --git a/user_guide_src/source/general/controllers.rst b/user_guide_src/source/general/controllers.rst
index 5a111d8dc..14e583636 100644
--- a/user_guide_src/source/general/controllers.rst
+++ b/user_guide_src/source/general/controllers.rst
@@ -337,4 +337,4 @@ list.
That's it!
==========
-That, in a nutshell, is all there is to know about controllers. \ No newline at end of file
+That, in a nutshell, is all there is to know about controllers.
diff --git a/user_guide_src/source/general/core_classes.rst b/user_guide_src/source/general/core_classes.rst
index 79f73ef06..9ccded75c 100644
--- a/user_guide_src/source/general/core_classes.rst
+++ b/user_guide_src/source/general/core_classes.rst
@@ -83,6 +83,7 @@ application/core/MY_Input.php, and declare your class with::
public function __construct()
{
parent::__construct();
+ // Your own constructor code
}
}
@@ -98,12 +99,6 @@ your new class in your application controller's constructors.
class Welcome extends MY_Controller {
- public function __construct()
- {
- parent::__construct();
- // Your own constructor code
- }
-
public function index()
{
$this->load->view('welcome_message');
@@ -119,4 +114,4 @@ To set your own sub-class prefix, open your
$config['subclass_prefix'] = 'MY_';
Please note that all native CodeIgniter libraries are prefixed
-with CI\_ so DO NOT use that as your prefix. \ No newline at end of file
+with CI\_ so DO NOT use that as your prefix.
diff --git a/user_guide_src/source/general/creating_libraries.rst b/user_guide_src/source/general/creating_libraries.rst
index d6b0631af..83742b619 100644
--- a/user_guide_src/source/general/creating_libraries.rst
+++ b/user_guide_src/source/general/creating_libraries.rst
@@ -224,6 +224,7 @@ extend the parent constructor::
public function __construct($config = array())
{
parent::__construct($config);
+ // Your own constructor code
}
}
@@ -256,4 +257,4 @@ To set your own sub-class prefix, open your
$config['subclass_prefix'] = 'MY_';
Please note that all native CodeIgniter libraries are prefixed with CI\_
-so DO NOT use that as your prefix. \ No newline at end of file
+so DO NOT use that as your prefix.
diff --git a/user_guide_src/source/general/models.rst b/user_guide_src/source/general/models.rst
index eb842e927..0b20164e9 100644
--- a/user_guide_src/source/general/models.rst
+++ b/user_guide_src/source/general/models.rst
@@ -67,12 +67,6 @@ The basic prototype for a model class is this::
class Model_name extends CI_Model {
- public function __construct()
- {
- parent::__construct();
- // Your own constructor code
- }
-
}
Where **Model_name** is the name of your class. Class names **must** have
@@ -83,12 +77,6 @@ The file name must match the class name. For example, if this is your class::
class User_model extends CI_Model {
- public function __construct()
- {
- parent::__construct();
- // Your own constructor code
- }
-
}
Your file will be this::
@@ -176,4 +164,4 @@ database. The following options for connecting are available to you:
$config['pconnect'] = FALSE;
$config['db_debug'] = TRUE;
- $this->load->model('model_name', '', $config); \ No newline at end of file
+ $this->load->model('model_name', '', $config);
diff --git a/user_guide_src/source/general/urls.rst b/user_guide_src/source/general/urls.rst
index e23554907..b8a1b9f5b 100644
--- a/user_guide_src/source/general/urls.rst
+++ b/user_guide_src/source/general/urls.rst
@@ -42,9 +42,9 @@ By default, the **index.php** file will be included in your URLs::
If your Apache server has *mod_rewrite* enabled, you can easily remove this
file by using a .htaccess file with some simple rules. Here is an example
of such a file, using the "negative" method in which everything is redirected
-except the specified items::
+except the specified items:
-.. code-block:: console
+.. code-block:: apache
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f