summaryrefslogtreecommitdiffstats
path: root/user_guide_src/source/general
diff options
context:
space:
mode:
Diffstat (limited to 'user_guide_src/source/general')
-rw-r--r--user_guide_src/source/general/ancillary_classes.rst2
-rw-r--r--user_guide_src/source/general/autoloader.rst6
-rw-r--r--user_guide_src/source/general/common_functions.rst2
-rw-r--r--user_guide_src/source/general/compatibility_functions.rst47
-rw-r--r--user_guide_src/source/general/creating_drivers.rst6
-rw-r--r--user_guide_src/source/general/creating_libraries.rst2
-rw-r--r--user_guide_src/source/general/routing.rst4
7 files changed, 46 insertions, 23 deletions
diff --git a/user_guide_src/source/general/ancillary_classes.rst b/user_guide_src/source/general/ancillary_classes.rst
index edb3a14fb..f9b6ba231 100644
--- a/user_guide_src/source/general/ancillary_classes.rst
+++ b/user_guide_src/source/general/ancillary_classes.rst
@@ -78,7 +78,7 @@ Example::
public function bar()
{
- $this->CI->config_item('base_url');
+ $this->CI->config->item('base_url');
}
}
diff --git a/user_guide_src/source/general/autoloader.rst b/user_guide_src/source/general/autoloader.rst
index bf2e3935a..2f1223e28 100644
--- a/user_guide_src/source/general/autoloader.rst
+++ b/user_guide_src/source/general/autoloader.rst
@@ -20,4 +20,8 @@ file and add the item you want loaded to the autoload array. You'll
find instructions in that file corresponding to each type of item.
.. note:: Do not include the file extension (.php) when adding items to
- the autoload array. \ No newline at end of file
+ the autoload array.
+
+Additionally, if you want CodeIgniter to use a `Composer <https://getcomposer.org/>`_
+auto-loader, just set ``$config['composer_autoload']`` to ``TRUE`` or
+a custom path in **application/config/config.php**. \ No newline at end of file
diff --git a/user_guide_src/source/general/common_functions.rst b/user_guide_src/source/general/common_functions.rst
index 9c0a7cbe1..399a323cc 100644
--- a/user_guide_src/source/general/common_functions.rst
+++ b/user_guide_src/source/general/common_functions.rst
@@ -63,7 +63,7 @@ loading any libraries or helpers.
.. function:: config_item($key)
:param string $key: Config item key
- :returns: Configuration key value or FALSE if not found
+ :returns: Configuration key value or NULL if not found
:rtype: mixed
The :doc:`Config Library <../libraries/config>` is the preferred way of
diff --git a/user_guide_src/source/general/compatibility_functions.rst b/user_guide_src/source/general/compatibility_functions.rst
index e685073a1..aee9b1ef0 100644
--- a/user_guide_src/source/general/compatibility_functions.rst
+++ b/user_guide_src/source/general/compatibility_functions.rst
@@ -7,12 +7,12 @@ you to use functions what are otherwise natively available in PHP,
but only in higher versions or depending on a certain extension.
Being custom implementations, these functions will also have some
-set of dependancies on their own, but are still useful if your
+set of dependencies on their own, but are still useful if your
PHP setup doesn't offer them natively.
.. note:: Much like the `common functions <common_functions>`, the
compatibility functions are always available, as long as
- their dependancies are met.
+ their dependencies are met.
.. contents::
:local:
@@ -29,7 +29,7 @@ This set of compatibility functions offers a "backport" of PHP's
standard `Password Hashing extension <http://php.net/password>`_
that is otherwise available only since PHP 5.5.
-Dependancies
+Dependencies
============
- PHP 5.3.7
@@ -65,7 +65,7 @@ Function reference
password_hash() <http://php.net/password_hash>`_.
.. note:: Unless you provide your own (and valid) salt, this function
- has a further dependancy on an available CSPRNG source. Each
+ has a further dependency on an available CSPRNG source. Each
of the following would satisfy that:
- ``mcrypt_create_iv()`` with ``MCRYPT_DEV_URANDOM``
- ``openssl_random_pseudo_bytes()``
@@ -101,7 +101,7 @@ This compatibility layer contains backports for the ``hash_equals()``
and ``hash_pbkdf2()`` functions, which otherwise require PHP 5.6 and/or
PHP 5.5 respectively.
-Dependancies
+Dependencies
============
- None
@@ -144,19 +144,19 @@ the limited alternative solutions, only a few functions are available.
.. note:: When a character set parameter is ommited,
``$config['charset']`` will be used.
-Dependancies
+Dependencies
============
- `iconv <http://php.net/iconv>`_ extension
-.. important:: This dependancy is optional and these functions will
+.. important:: This dependency is optional and these functions will
always be declared. If iconv is not available, they WILL
fall-back to their non-mbstring versions.
.. important:: Where a character set is supplied, it must be
supported by iconv and in a format that it recognizes.
-.. note:: For you own dependancy check on the actual mbstring
+.. note:: For you own dependency check on the actual mbstring
extension, use the ``MB_ENABLED`` constant.
Function reference
@@ -196,15 +196,14 @@ Function reference
For more information, please refer to the `PHP manual for
mb_substr() <http://php.net/mb_substr>`_.
-***************
-Array Functions
-***************
+******************
+Standard Functions
+******************
This set of compatibility functions offers support for a few
-standard `Array Functions <http://php.net/book.array>`_ in PHP
-that otherwise require a newer PHP version.
+standard functions in PHP that otherwise require a newer PHP version.
-Dependancies
+Dependencies
============
- None
@@ -244,4 +243,22 @@ Function reference
array_replace_recursive() <http://php.net/array_replace_recursive>`_.
.. important:: Only PHP's native function can detect endless recursion.
- Unless you are running PHP 5.3+, be careful with references! \ No newline at end of file
+ Unless you are running PHP 5.3+, be careful with references!
+
+.. function:: hex2bin($data)
+
+ :param array $data: Hexadecimal representation of data
+ :returns: Binary representation of the given data
+ :rtype: string
+
+ For more information, please refer to the `PHP manual for hex2bin()
+ <http://php.net/hex2bin>`_.
+
+.. function:: quoted_printable_encode($str)
+
+ :param string $str: Input string
+ :returns: 8bit-encoded string
+ :rtype: string
+
+ For more information, please refer to the `PHP manual for
+ quoted_printable_encode() <http://php.net/quoted_printable_encode>`_. \ No newline at end of file
diff --git a/user_guide_src/source/general/creating_drivers.rst b/user_guide_src/source/general/creating_drivers.rst
index cf4ea5d7f..63ac83902 100644
--- a/user_guide_src/source/general/creating_drivers.rst
+++ b/user_guide_src/source/general/creating_drivers.rst
@@ -18,4 +18,8 @@ Sample driver directory and file structure layout:
.. note:: In order to maintain compatibility on case-sensitive
file systems, the Driver_name directory must be
- named in the format returned by ``ucfirst()``. \ No newline at end of file
+ named in the format returned by ``ucfirst()``.
+
+.. note:: The Driver library's architecture is such that
+ the subclasses don't extend and therefore don't inherit
+ properties or methods of the main driver. \ No newline at end of file
diff --git a/user_guide_src/source/general/creating_libraries.rst b/user_guide_src/source/general/creating_libraries.rst
index a1e1b3e78..0e3ae4c85 100644
--- a/user_guide_src/source/general/creating_libraries.rst
+++ b/user_guide_src/source/general/creating_libraries.rst
@@ -170,7 +170,7 @@ methods, you're encouraged to assign it to a property instead::
public function bar()
{
- echo $this->CI->config_item('base_url');
+ echo $this->CI->config->item('base_url');
}
}
diff --git a/user_guide_src/source/general/routing.rst b/user_guide_src/source/general/routing.rst
index 0b91d3fa9..766e0b2ab 100644
--- a/user_guide_src/source/general/routing.rst
+++ b/user_guide_src/source/general/routing.rst
@@ -116,15 +116,13 @@ call the "shirts" controller class and the "id_123" method.
With regular expressions, you can also catch a segment containing a
forward slash ('/'), which would usually represent the delimiter between
multiple segments.
+
For example, if a user accesses a password protected area of your web
application and you wish to be able to redirect them back to the same
page after they log in, you may find this example useful::
$route['login/(.+)'] = 'auth/login/$1';
-That will call the "auth" controller class and its ``login()`` method,
-passing everything contained in the URI after *login/* as a parameter.
-
For those of you who don't know regular expressions and want to learn
more about them, `regular-expressions.info <http://www.regular-expressions.info/>`
might be a good starting point.