summaryrefslogtreecommitdiffstats
path: root/user_guide_src/source/installation/upgrade_300.rst
diff options
context:
space:
mode:
authorAndrey Andreev <narf@devilix.net>2013-11-12 16:04:55 +0100
committerAndrey Andreev <narf@devilix.net>2013-11-12 16:04:55 +0100
commitf964b16f3db95d655420dfae2012ee9fbb98a1a8 (patch)
treea3a2acf87bf15604da653c67e1a348097225f817 /user_guide_src/source/installation/upgrade_300.rst
parent35e3b0bc4f723b938160da87aeb5ad9e054507c4 (diff)
Deprecate CI_Input::is_cli_request() and add common function is_cli() to replace it
Calls to this function are often needed before the Input library is available
Diffstat (limited to 'user_guide_src/source/installation/upgrade_300.rst')
-rw-r--r--user_guide_src/source/installation/upgrade_300.rst24
1 files changed, 24 insertions, 0 deletions
diff --git a/user_guide_src/source/installation/upgrade_300.rst b/user_guide_src/source/installation/upgrade_300.rst
index e8fdd0b15..8f9cc1bdc 100644
--- a/user_guide_src/source/installation/upgrade_300.rst
+++ b/user_guide_src/source/installation/upgrade_300.rst
@@ -457,4 +457,28 @@ then you can now just access the properties instead::
$this->router->method;
.. note:: Those methods are still available, but you're strongly encouraged to remove their usage
+ sooner rather than later.
+
+Input library method is_cli_request()
+=====================================
+
+Calls to the ``CI_Input::is_cli_request()`` method are necessary at many places
+in the CodeIgniter internals and this is often before the :doc:`Input Library
+<../libraries/input>` is loaded. Because of that, it is being replaced by a common
+function named :php:func:`is_cli()` and this method is now just an alias.
+
+The new function is both available at all times for you to use and shorter to type.
+
+::
+
+ // Old
+ $this->input->is_cli_request();
+
+ // New
+ is_cli();
+
+``CI_Input::is_cli_request()`` is now now deprecated and scheduled for removal in
+CodeIgniter 3.1+.
+
+.. note:: This method is still available, but you're strongly encouraged to remove its usage
sooner rather than later. \ No newline at end of file