From e52fc267a93fd3627951ddc7c5109b573a871727 Mon Sep 17 00:00:00 2001 From: Andrey Andreev Date: Tue, 11 Feb 2014 13:27:01 +0200 Subject: Fix issue #43 --- user_guide_src/source/changelog.rst | 1 + 1 file changed, 1 insertion(+) (limited to 'user_guide_src') diff --git a/user_guide_src/source/changelog.rst b/user_guide_src/source/changelog.rst index 1e43ab23c..e08b7fee0 100644 --- a/user_guide_src/source/changelog.rst +++ b/user_guide_src/source/changelog.rst @@ -693,6 +693,7 @@ Bug fixes for 3.0 - Fixed a bug (#2771) - :doc:`Security Library ` method ``xss_clean()`` didn't take into account HTML5 entities. - Fixed a bug in the :doc:`Session Library ` 'cookie' driver where authentication was not performed for encrypted cookies. - Fixed a bug (#2856) - ODBC method ``affected_rows()`` passed an incorrect value to ``odbc_num_rows()``. +- Fixed a bug (#43) :doc:`Image Manipulation Library ` method ``text_watermark()`` didn't properly determine watermark placement. Version 2.1.4 ============= -- cgit v1.2.3-24-g4f1b From 05983fcb5b8f04fb895c025e28ef6ffc44a5f602 Mon Sep 17 00:00:00 2001 From: Andrey Andreev Date: Tue, 11 Feb 2014 16:51:43 +0200 Subject: A bug fix and optimizations in CI_Table --- user_guide_src/source/changelog.rst | 1 + 1 file changed, 1 insertion(+) (limited to 'user_guide_src') diff --git a/user_guide_src/source/changelog.rst b/user_guide_src/source/changelog.rst index e08b7fee0..9e63a6885 100644 --- a/user_guide_src/source/changelog.rst +++ b/user_guide_src/source/changelog.rst @@ -694,6 +694,7 @@ Bug fixes for 3.0 - Fixed a bug in the :doc:`Session Library ` 'cookie' driver where authentication was not performed for encrypted cookies. - Fixed a bug (#2856) - ODBC method ``affected_rows()`` passed an incorrect value to ``odbc_num_rows()``. - Fixed a bug (#43) :doc:`Image Manipulation Library ` method ``text_watermark()`` didn't properly determine watermark placement. +- Fixed a bug where :doc:`HTML Table Library ` ignored its *auto_heading* setting if headings were not already set. Version 2.1.4 ============= -- cgit v1.2.3-24-g4f1b From a49c8adbc24d904b3473cc301f0f56818acdddcb Mon Sep 17 00:00:00 2001 From: Andrey Andreev Date: Tue, 11 Feb 2014 17:15:07 +0200 Subject: Change CI_Table:: to NULL Because semantics --- user_guide_src/source/libraries/table.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'user_guide_src') diff --git a/user_guide_src/source/libraries/table.rst b/user_guide_src/source/libraries/table.rst index 6e011083e..9d95eddfc 100644 --- a/user_guide_src/source/libraries/table.rst +++ b/user_guide_src/source/libraries/table.rst @@ -139,7 +139,7 @@ Class Reference .. class:: CI_Table - .. attribute:: $function = FALSE + .. attribute:: $function = NULL Allows you to specify a native PHP function or a valid function array object to be applied to all cell data. :: -- cgit v1.2.3-24-g4f1b From 871754af60251993d640981e107d2def5f2db396 Mon Sep 17 00:00:00 2001 From: darwinel Date: Tue, 11 Feb 2014 17:34:57 +0100 Subject: 2013 > 2014 Update copyright notices from 2013 to 2014. And update one calendar example in user_guide from year 2013/2014 to 2014/2015. --- user_guide_src/cilexer/cilexer/cilexer.py | 2 +- user_guide_src/source/_themes/eldocs/static/asset/css/common.css | 2 +- user_guide_src/source/conf.py | 4 ++-- user_guide_src/source/libraries/calendar.rst | 4 ++-- user_guide_src/source/tutorial/static_pages.rst | 2 +- 5 files changed, 7 insertions(+), 7 deletions(-) (limited to 'user_guide_src') diff --git a/user_guide_src/cilexer/cilexer/cilexer.py b/user_guide_src/cilexer/cilexer/cilexer.py index 1edc7e820..e9834ecb1 100644 --- a/user_guide_src/cilexer/cilexer/cilexer.py +++ b/user_guide_src/cilexer/cilexer/cilexer.py @@ -15,7 +15,7 @@ # through the world wide web, please send an email to # licensing@ellislab.com so we can send you a copy immediately. # -# Copyright (c) 2008 - 2013, EllisLab, Inc. (http://ellislab.com/) +# Copyright (c) 2008 - 2014, EllisLab, Inc. (http://ellislab.com/) # http://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0) diff --git a/user_guide_src/source/_themes/eldocs/static/asset/css/common.css b/user_guide_src/source/_themes/eldocs/static/asset/css/common.css index 962380b50..f0ce8c80c 100644 --- a/user_guide_src/source/_themes/eldocs/static/asset/css/common.css +++ b/user_guide_src/source/_themes/eldocs/static/asset/css/common.css @@ -16,7 +16,7 @@ If you did not receive a copy of the license and are unable to obtain it through the world wide web, please send an email to licensing@ellislab.com so we can send you a copy immediately. -Copyright (c) 2008 - 2013, EllisLab, Inc. (http://ellislab.com/) +Copyright (c) 2008 - 2014, EllisLab, Inc. (http://ellislab.com/) http://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0) */ diff --git a/user_guide_src/source/conf.py b/user_guide_src/source/conf.py index 6d77db060..3f9b2e476 100644 --- a/user_guide_src/source/conf.py +++ b/user_guide_src/source/conf.py @@ -41,7 +41,7 @@ master_doc = 'index' # General information about the project. project = u'CodeIgniter' -copyright = u'2013, EllisLab, Inc.' +copyright = u'2014, EllisLab, Inc.' # The version info for the project you're documenting, acts as replacement for # |version| and |release|, also used in various other places throughout the @@ -224,7 +224,7 @@ man_pages = [ epub_title = u'CodeIgniter' epub_author = u'EllisLab, Inc.' epub_publisher = u'EllisLab, Inc.' -epub_copyright = u'2013, EllisLab, Inc.' +epub_copyright = u'2014, EllisLab, Inc.' # The language of the text. It defaults to the language option # or en if the language is not set. diff --git a/user_guide_src/source/libraries/calendar.rst b/user_guide_src/source/libraries/calendar.rst index 65a447a3d..2263aa404 100644 --- a/user_guide_src/source/libraries/calendar.rst +++ b/user_guide_src/source/libraries/calendar.rst @@ -248,14 +248,14 @@ Class Reference you submit 13 as the month, the year will increment and the month will become January:: - print_r($this->calendar->adjust_date(13, 2013)); + print_r($this->calendar->adjust_date(13, 2014)); outputs:: Array (     [month] => '01' - [year] => '2014' + [year] => '2015' ) .. method:: get_total_days($month, $year) diff --git a/user_guide_src/source/tutorial/static_pages.rst b/user_guide_src/source/tutorial/static_pages.rst index 330a50ecf..36bcd2df9 100644 --- a/user_guide_src/source/tutorial/static_pages.rst +++ b/user_guide_src/source/tutorial/static_pages.rst @@ -72,7 +72,7 @@ includes the following code: :: - © 2013 + © 2014 -- cgit v1.2.3-24-g4f1b From 25f119cef588a01651cec7c59d3b03924b2dd81c Mon Sep 17 00:00:00 2001 From: darwinel Date: Tue, 11 Feb 2014 18:29:58 +0100 Subject: Writing style fix based on style guide MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit „Use of || is discouraged as its clarity on some output devices is low (looking like the number 11 for instance). && is preferred over AND but either are acceptable, and a space should always precede and follow !.” --- user_guide_src/source/libraries/xmlrpc.rst | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'user_guide_src') diff --git a/user_guide_src/source/libraries/xmlrpc.rst b/user_guide_src/source/libraries/xmlrpc.rst index 2cf548750..115b4e680 100644 --- a/user_guide_src/source/libraries/xmlrpc.rst +++ b/user_guide_src/source/libraries/xmlrpc.rst @@ -223,17 +223,17 @@ email address, etc.). Here is how the processing function might look:: $parameters = $request->output_parameters(); - if ($parameters['1'] != $username AND $parameters['2'] != $password) + if ($parameters['1'] != $username && $parameters['2'] != $password) { return $this->xmlrpc->send_error_message('100', 'Invalid Access'); } - $response = array(array('nickname' => array('Smitty','string'), - 'userid' => array('99','string'), - 'url' => array('http://yoursite.com','string'), - 'email' => array('jsmith@yoursite.com','string'), - 'lastname' => array('Smith','string'), - 'firstname' => array('John','string') + $response = array(array('nickname' => array('Smitty', 'string'), + 'userid' => array('99', 'string'), + 'url' => array('http://yoursite.com', 'string'), + 'email' => array('jsmith@yoursite.com', 'string'), + 'lastname' => array('Smith', 'string'), + 'firstname' => array('John', 'string') ), 'struct'); -- cgit v1.2.3-24-g4f1b From d8bef8a878238c6974f01758469af1c13ac8b8d7 Mon Sep 17 00:00:00 2001 From: darwinel Date: Tue, 11 Feb 2014 20:13:22 +0100 Subject: "BASEPATH check" consistency MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit As described in issue #2870 + A change in the „How to create a library” example in the user_guide --- user_guide_src/source/general/creating_libraries.rst | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'user_guide_src') diff --git a/user_guide_src/source/general/creating_libraries.rst b/user_guide_src/source/general/creating_libraries.rst index 4beb600da..a1e1b3e78 100644 --- a/user_guide_src/source/general/creating_libraries.rst +++ b/user_guide_src/source/general/creating_libraries.rst @@ -44,7 +44,8 @@ The Class File Classes should have this basic prototype:: - Date: Tue, 11 Feb 2014 21:45:39 +0200 Subject: [ci skip] Update the XML-RPC lib docs --- user_guide_src/source/libraries/xmlrpc.rst | 131 +++++++++++++++-------------- 1 file changed, 66 insertions(+), 65 deletions(-) (limited to 'user_guide_src') diff --git a/user_guide_src/source/libraries/xmlrpc.rst b/user_guide_src/source/libraries/xmlrpc.rst index 115b4e680..c2e9a1113 100644 --- a/user_guide_src/source/libraries/xmlrpc.rst +++ b/user_guide_src/source/libraries/xmlrpc.rst @@ -123,12 +123,12 @@ If you use data types other than strings, or if you have several different data types, you will place each parameter into its own array, with the data type in the second position:: - $request = array ( - array('John', 'string'), - array('Doe', 'string'), - array(FALSE, 'boolean'), - array(12345, 'int') - ); + $request = array( + array('John', 'string'), + array('Doe', 'string'), + array(FALSE, 'boolean'), + array(12345, 'int') + ); $this->xmlrpc->request($request); The `Data Types <#datatypes>`_ section below has a full list of data @@ -171,7 +171,7 @@ not part of the CodeIgniter super object. In other words, if an XML-RPC Client sends a request for the new_post method, your server will load the My_blog class and call the new_entry function. If the request is for the update_post method, your server -will load the My_blog class and call the update_entry function. +will load the My_blog class and call the ``update_entry()`` method. The function names in the above example are arbitrary. You'll decide what they should be called on your server, or if you are using @@ -181,7 +181,7 @@ function names. There are two additional configuration keys you may make use of when initializing the server class: debug can be set to TRUE in order to enable debugging, and xss_clean may be set to FALSE to prevent sending -data through the Security library's xss_clean function. +data through the Security library's ``xss_clean()`` method. Processing Server Requests ========================== @@ -207,49 +207,52 @@ have access to the *request parameters* enabling you to process the request. When you are done you will send a Response back to the Client. Below is a real-world example, using the Blogger API. One of the methods -in the Blogger API is getUserInfo(). Using this method, an XML-RPC +in the Blogger API is ``getUserInfo()``. Using this method, an XML-RPC Client can send the Server a username and password, in return the Server sends back information about that particular user (nickname, user ID, email address, etc.). Here is how the processing function might look:: class My_blog extends CI_Controller { - function getUserInfo($request) - { - $username = 'smitty'; - $password = 'secretsmittypass'; + public function getUserInfo($request) + { + $username = 'smitty'; + $password = 'secretsmittypass'; - $this->load->library('xmlrpc'); + $this->load->library('xmlrpc'); - $parameters = $request->output_parameters(); + $parameters = $request->output_parameters(); - if ($parameters['1'] != $username && $parameters['2'] != $password) - { - return $this->xmlrpc->send_error_message('100', 'Invalid Access'); - } + if ($parameters[1] != $username && $parameters[2] != $password) + { + return $this->xmlrpc->send_error_message('100', 'Invalid Access'); + } - $response = array(array('nickname' => array('Smitty', 'string'), - 'userid' => array('99', 'string'), - 'url' => array('http://yoursite.com', 'string'), - 'email' => array('jsmith@yoursite.com', 'string'), - 'lastname' => array('Smith', 'string'), - 'firstname' => array('John', 'string') - ), - 'struct'); + $response = array( + array( + 'nickname' => array('Smitty', 'string'), + 'userid' => array('99', 'string'), + 'url' => array('http://yoursite.com', 'string'), + 'email' => array('jsmith@yoursite.com', 'string'), + 'lastname' => array('Smith', 'string'), + 'firstname' => array('John', 'string') + ), + 'struct' + ); - return $this->xmlrpc->send_response($response); - } + return $this->xmlrpc->send_response($response); + } } Notes: ------ -The output_parameters() function retrieves an indexed array +The ``output_parameters()`` method retrieves an indexed array corresponding to the request parameters sent by the client. In the above example, the output parameters will be the username and password. If the username and password sent by the client were not valid, and -error message is returned using send_error_message(). +error message is returned using ``send_error_message()``. If the operation was successful, the client will be sent back a response array containing the user's info. @@ -263,22 +266,22 @@ single item**. This item can be an array with several additional arrays, but there can be only one primary array index. In other words, the basic prototype is this:: - $response = array('Response data', 'array'); + $response = array('Response data', 'array'); Responses, however, usually contain multiple pieces of information. In order to accomplish this we must put the response into its own array so that the primary array continues to contain a single piece of data. Here's an example showing how this might be accomplished:: - $response = array ( - array( - 'first_name' => array('John', 'string'), - 'last_name' => array('Doe', 'string'), - 'member_id' => array(123435, 'int'), - 'todo_list' => array(array('clean house', 'call mom', 'water plants'), 'array'), - ), - 'struct' - ); + $response = array( + array( + 'first_name' => array('John', 'string'), + 'last_name' => array('Doe', 'string'), + 'member_id' => array(123435, 'int'), + 'todo_list' => array(array('clean house', 'call mom', 'water plants'), 'array'), + ), + 'struct' + ); Notice that the above array is formatted as a struct. This is the most common data type for responses. @@ -373,17 +376,16 @@ folder:: $parameters = $request->output_parameters(); $response = array( - array( - 'you_said' => $parameters[0], - 'i_respond' => 'Not bad at all.' - ), - 'struct' - ); + array( + 'you_said' => $parameters[0], + 'i_respond' => 'Not bad at all.' + ), + 'struct' + ); return $this->xmlrpc->send_response($response); } } - ?> Try it! @@ -398,7 +400,7 @@ back to you. The client you created sends a message ("How's is going?") to the server, along with a request for the "Greetings" method. The Server -receives the request and maps it to the "process" function, where a +receives the request and maps it to the ``process()`` method, where a response is sent back. Using Associative Arrays In a Request Parameter @@ -408,22 +410,21 @@ If you wish to use an associative array in your method parameters you will need to use a struct datatype:: $request = array( - array( - // Param 0 - array( - 'name'=>'John' - ), - 'struct' - ), - array( - // Param 1 - array( - 'size'=>'large', - 'shape'=>'round' - ), - 'struct' - ) - ); + array( + // Param 0 + array('name' => 'John'), + 'struct' + ), + array( + // Param 1 + array( + 'size' => 'large', + 'shape'=>'round' + ), + 'struct' + ) + ); + $this->xmlrpc->request($request); You can retrieve the associative array when processing the request in -- cgit v1.2.3-24-g4f1b From be1496d1a8618ef186047468009c7e3e0640183b Mon Sep 17 00:00:00 2001 From: Andrey Andreev Date: Tue, 11 Feb 2014 22:48:45 +0200 Subject: Utf8/iconv/mbstring-related changes --- user_guide_src/source/changelog.rst | 7 +++++++ user_guide_src/source/general/reserved_names.rst | 3 +++ 2 files changed, 10 insertions(+) (limited to 'user_guide_src') diff --git a/user_guide_src/source/changelog.rst b/user_guide_src/source/changelog.rst index 9e63a6885..b5b31dcc2 100644 --- a/user_guide_src/source/changelog.rst +++ b/user_guide_src/source/changelog.rst @@ -396,6 +396,7 @@ Release Date: Not Released - Added support for setting table class defaults in a config file. - :doc:`Zip Library ` method ``read_file()`` can now also alter the original file path/name while adding files to an archive. + - :doc:`Trackback Library ` method ``receive()`` will now utilize ``iconv()`` if it is available but ``mb_convert_encoding()`` is not. - Core @@ -489,9 +490,15 @@ Release Date: Not Released - Language files are now loaded in a cascading style with the one in **system/** always loaded and overriden afterwards, if another one is found. - :doc:`Hooks Library ` changes include: + - Renamed method ``_call_hook()`` to ``call_hook()``. - Class instances are now stored in order to maintain their state. + - UTF-8 Library changes include: + + - ``UTF8_ENABLED`` now requires only one of `Multibyte String `_ or `iconv `_ to be available instead of both. + - Changed method ``clean_string()`` to utilize ``mb_convert_encoding()`` if it is available but ``iconv()`` is not. + - Removed ``CI_CORE`` boolean constant from *CodeIgniter.php* (no longer Reactor and Core versions). - Log Library will now try to create the **log_path** directory if it doesn't exist. - Added support for HTTP-Only cookies with new config option *cookie_httponly* (default FALSE). diff --git a/user_guide_src/source/general/reserved_names.rst b/user_guide_src/source/general/reserved_names.rst index a767651fb..81a05ace6 100644 --- a/user_guide_src/source/general/reserved_names.rst +++ b/user_guide_src/source/general/reserved_names.rst @@ -61,6 +61,9 @@ Constants - APPPATH - VIEWPATH - CI_VERSION +- MB_ENABLED +- ICONV_ENABLED +- UTF8_ENABLED - FILE_READ_MODE - FILE_WRITE_MODE - DIR_READ_MODE -- cgit v1.2.3-24-g4f1b From 7d16de620a46f84ffeb52a54ae82439a06f89c74 Mon Sep 17 00:00:00 2001 From: Ahmad Anbar Date: Thu, 13 Feb 2014 01:45:27 +0200 Subject: Fixed code style & added few extra checks. Updated cart documentation. --- user_guide_src/source/libraries/cart.rst | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'user_guide_src') diff --git a/user_guide_src/source/libraries/cart.rst b/user_guide_src/source/libraries/cart.rst index fb92c280a..015f1c90e 100644 --- a/user_guide_src/source/libraries/cart.rst +++ b/user_guide_src/source/libraries/cart.rst @@ -194,7 +194,9 @@ Updating The Cart To update the information in your cart, you must pass an array containing the Row ID and quantity to the $this->cart->update() -function: +function, you may also update any property you have previously +defined when inserting the item such like (options, price +or other custom fields you defined). .. note:: If the quantity is set to zero, the item will be removed from the cart. @@ -289,10 +291,10 @@ Class Reference :returns: TRUE on success, FALSE on failure :rtype: bool - This method permits the quantity of a given item to be changed. + This method permits changing the properties of a given item. Typically it is called from the "view cart" page if a user makes changes - to the quantity before checkout. That array must contain the product ID - and quantity for each item. + to the quantity before checkout. That array must contain the rowid + and qty for each item. .. method:: remove($rowid) -- cgit v1.2.3-24-g4f1b From 3fd1b384273b7b6d56950bbad3e1fac18f5f82e4 Mon Sep 17 00:00:00 2001 From: Andrey Andreev Date: Thu, 13 Feb 2014 03:01:31 +0200 Subject: Introducing compatibility layers - Limited support for mbstring (mb_strlen(), mb_strpos(), mb_substr() only) via iconv. Falls back to regular strlen(), strpos(), substr() if iconv is not available. - Password hashing, dependant on CRYPT_BLOWFISH (2y version, available since PHP 5.3.7) availability. --- user_guide_src/source/changelog.rst | 1 + 1 file changed, 1 insertion(+) (limited to 'user_guide_src') diff --git a/user_guide_src/source/changelog.rst b/user_guide_src/source/changelog.rst index b5b31dcc2..ce84b7f54 100644 --- a/user_guide_src/source/changelog.rst +++ b/user_guide_src/source/changelog.rst @@ -499,6 +499,7 @@ Release Date: Not Released - ``UTF8_ENABLED`` now requires only one of `Multibyte String `_ or `iconv `_ to be available instead of both. - Changed method ``clean_string()`` to utilize ``mb_convert_encoding()`` if it is available but ``iconv()`` is not. + - Added compatibility layers for PHP's `Multibyte string `_ (limited support) and `Password Hashing ` extensions. - Removed ``CI_CORE`` boolean constant from *CodeIgniter.php* (no longer Reactor and Core versions). - Log Library will now try to create the **log_path** directory if it doesn't exist. - Added support for HTTP-Only cookies with new config option *cookie_httponly* (default FALSE). -- cgit v1.2.3-24-g4f1b From 6ce4746474ddf050f7f4df61b7a22b7f5854d533 Mon Sep 17 00:00:00 2001 From: Andrey Andreev Date: Thu, 13 Feb 2014 03:28:00 +0200 Subject: Update Text and Inflector helpers to utilize mbstring, if available Text: word_wrap(), ellipsize() Inflector: humanize(), underscore() (rel #2855) --- user_guide_src/source/changelog.rst | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) (limited to 'user_guide_src') diff --git a/user_guide_src/source/changelog.rst b/user_guide_src/source/changelog.rst index ce84b7f54..16c30b795 100644 --- a/user_guide_src/source/changelog.rst +++ b/user_guide_src/source/changelog.rst @@ -90,7 +90,8 @@ Release Date: Not Released - :doc:`Inflector Helper ` changes include: - Changed :func:`humanize()` to allow passing an input separator as its second parameter. - - Refactored :func:`plural()` and :func:`singular()` to avoid double pluralization and support more words. + - Changed :func:`humanize()` and :func:`underscore()` to utilize `mbstring `_, if available. + - Changed :func:`plural()` and :func:`singular()` to avoid double pluralization and support more words. - :doc:`Download Helper ` changes include: @@ -132,10 +133,14 @@ Release Date: Not Released - Added *colors* configuration to allow customization for the *background*, *border*, *text* and *grid* colors. - Added *filename* to the returned array elements. + - :doc:`Text Helper ` changes include: + + - Changed the default tag for use in :func:`highlight_phrase()` to ```` (formerly ````). + - Changed :func:`character_limiter()`, :func:`word_wrap()` and :func:`ellipsize()` to utilize `mbstring `_ or `iconv `_, if available. + - :doc:`Directory Helper ` :func:`directory_map()` will now append ``DIRECTORY_SEPARATOR`` to directory names in the returned array. - :doc:`Array Helper ` :func:`element()` and :func:`elements()` now return NULL instead of FALSE when the required elements don't exist. - :doc:`Language Helper ` :func:`lang()` now accepts an optional list of additional HTML attributes. - - Changed the default tag for use in :doc:`Text Helper ` :func:`highlight_phrase()` to ```` (formerly ````). - Deprecated the :doc:`Email Helper ` as its ``valid_email()``, ``send_email()`` functions are now only aliases for PHP native functions ``filter_var()`` and ``mail()`` respectively. - Database @@ -499,7 +504,7 @@ Release Date: Not Released - ``UTF8_ENABLED`` now requires only one of `Multibyte String `_ or `iconv `_ to be available instead of both. - Changed method ``clean_string()`` to utilize ``mb_convert_encoding()`` if it is available but ``iconv()`` is not. - - Added compatibility layers for PHP's `Multibyte string `_ (limited support) and `Password Hashing ` extensions. + - Added compatibility layers for PHP's `mbstring `_ (limited support) and `password `_ extensions. - Removed ``CI_CORE`` boolean constant from *CodeIgniter.php* (no longer Reactor and Core versions). - Log Library will now try to create the **log_path** directory if it doesn't exist. - Added support for HTTP-Only cookies with new config option *cookie_httponly* (default FALSE). -- cgit v1.2.3-24-g4f1b From 576439fda03d4e81cb5b0cfed371f7776a73fe3a Mon Sep 17 00:00:00 2001 From: Ahmad Anbar Date: Thu, 13 Feb 2014 06:16:31 +0200 Subject: Added changelog entry. An example to the docs. Tidy code a little bit. --- user_guide_src/source/changelog.rst | 1 + user_guide_src/source/libraries/cart.rst | 17 +++++++++++++++-- 2 files changed, 16 insertions(+), 2 deletions(-) (limited to 'user_guide_src') diff --git a/user_guide_src/source/changelog.rst b/user_guide_src/source/changelog.rst index b5b31dcc2..76ee7ed31 100644 --- a/user_guide_src/source/changelog.rst +++ b/user_guide_src/source/changelog.rst @@ -303,6 +303,7 @@ Release Date: Not Released - Added method ``remove()`` to remove a cart item, updating with quantity of 0 seemed like a hack but has remained to retain compatibility. - Added method ``get_item()`` to enable retrieving data for a single cart item. - Added unicode support for product names. + - ``update()`` now supports updating all properties attached to an item. - :doc:`Image Manipulation Library ` changes include: diff --git a/user_guide_src/source/libraries/cart.rst b/user_guide_src/source/libraries/cart.rst index 015f1c90e..6d0dd2e3a 100644 --- a/user_guide_src/source/libraries/cart.rst +++ b/user_guide_src/source/libraries/cart.rst @@ -88,6 +88,18 @@ array will be stored in the session. However, it is best to standardize your data among all your products in order to make displaying the information in a table easier. +:: + + $data = array( + 'id' => 'sku_123ABC', + 'qty' => 1, + 'price' => 39.95, + 'name' => 'T-Shirt', + 'coupon' => 'XMAS-50OFF' + ); + + $this->cart->insert($data); + The insert() method will return the $rowid if you successfully insert a single item. @@ -195,8 +207,8 @@ Updating The Cart To update the information in your cart, you must pass an array containing the Row ID and quantity to the $this->cart->update() function, you may also update any property you have previously -defined when inserting the item such like (options, price -or other custom fields you defined). +defined when inserting the item such as options, price +or other custom fields you defined. .. note:: If the quantity is set to zero, the item will be removed from the cart. @@ -205,6 +217,7 @@ or other custom fields you defined). $data = array( 'rowid' => 'b99ccdf16028f015540f341130b6d8ec', + 'price' => 10, 'qty' => 3 ); -- cgit v1.2.3-24-g4f1b From da2bdf2b95a55f03aadfb6a1d21a90a0fff627db Mon Sep 17 00:00:00 2001 From: Ahmad Anbar Date: Thu, 13 Feb 2014 12:59:18 +0200 Subject: Re-arranged documentation, fixed comment. --- user_guide_src/source/libraries/cart.rst | 19 +++++++++++++++---- 1 file changed, 15 insertions(+), 4 deletions(-) (limited to 'user_guide_src') diff --git a/user_guide_src/source/libraries/cart.rst b/user_guide_src/source/libraries/cart.rst index 6d0dd2e3a..a0870e34a 100644 --- a/user_guide_src/source/libraries/cart.rst +++ b/user_guide_src/source/libraries/cart.rst @@ -206,9 +206,7 @@ Updating The Cart To update the information in your cart, you must pass an array containing the Row ID and quantity to the $this->cart->update() -function, you may also update any property you have previously -defined when inserting the item such as options, price -or other custom fields you defined. +function. .. note:: If the quantity is set to zero, the item will be removed from the cart. @@ -217,7 +215,6 @@ or other custom fields you defined. $data = array( 'rowid' => 'b99ccdf16028f015540f341130b6d8ec', - 'price' => 10, 'qty' => 3 ); @@ -242,6 +239,20 @@ or other custom fields you defined. $this->cart->update($data); +You may also update any property you have previously +defined when inserting the item such as options, price +or other custom fields you defined. + +:: + $data = array( + 'rowid' => 'b99ccdf16028f015540f341130b6d8ec', + 'qty' => 1, + 'price' => 49.95, + 'coupon' => NULL + ); + + $this->cart->update($data); + What is a Row ID? ***************** -- cgit v1.2.3-24-g4f1b From c09b953be9d14158cc21cecc676f7e992c16f752 Mon Sep 17 00:00:00 2001 From: Ahmad Anbar Date: Thu, 13 Feb 2014 13:05:41 +0200 Subject: Added Missing new line. --- user_guide_src/source/libraries/cart.rst | 1 + 1 file changed, 1 insertion(+) (limited to 'user_guide_src') diff --git a/user_guide_src/source/libraries/cart.rst b/user_guide_src/source/libraries/cart.rst index a0870e34a..74e791554 100644 --- a/user_guide_src/source/libraries/cart.rst +++ b/user_guide_src/source/libraries/cart.rst @@ -244,6 +244,7 @@ defined when inserting the item such as options, price or other custom fields you defined. :: + $data = array( 'rowid' => 'b99ccdf16028f015540f341130b6d8ec', 'qty' => 1, -- cgit v1.2.3-24-g4f1b From 0bd390c660290b7dc478955da6a8a7fbb3ca9fd6 Mon Sep 17 00:00:00 2001 From: Andrey Andreev Date: Thu, 13 Feb 2014 14:26:50 +0200 Subject: [ci skip] Polish changes from #2874 --- user_guide_src/source/changelog.rst | 6 +- user_guide_src/source/libraries/cart.rst | 125 +++++++++++++++---------------- 2 files changed, 65 insertions(+), 66 deletions(-) (limited to 'user_guide_src') diff --git a/user_guide_src/source/changelog.rst b/user_guide_src/source/changelog.rst index c8cbbb9e5..029bf61cb 100644 --- a/user_guide_src/source/changelog.rst +++ b/user_guide_src/source/changelog.rst @@ -303,12 +303,12 @@ Release Date: Not Released - :doc:`Cart Library ` changes include: - - ``insert()`` now auto-increments quantity for an item when inserted twice instead of resetting it, this is the default behaviour of large e-commerce sites. - - *Product Name* strictness can be disabled by switching the ``$product_name_safe`` property to FALSE. - Added method ``remove()`` to remove a cart item, updating with quantity of 0 seemed like a hack but has remained to retain compatibility. - Added method ``get_item()`` to enable retrieving data for a single cart item. - Added unicode support for product names. - - ``update()`` now supports updating all properties attached to an item. + - Added support for disabling product name strictness via the ``$product_name_safe`` property. + - Changed ``insert()`` method to auto-increment quantity for an item when inserted twice instead of resetting it. + - Changed ``update()`` method to support updating all properties attached to an item. - :doc:`Image Manipulation Library ` changes include: diff --git a/user_guide_src/source/libraries/cart.rst b/user_guide_src/source/libraries/cart.rst index 74e791554..8a473b49d 100644 --- a/user_guide_src/source/libraries/cart.rst +++ b/user_guide_src/source/libraries/cart.rst @@ -33,7 +33,7 @@ Initializing the Shopping Cart Class utilize a database. To initialize the Shopping Cart Class in your controller constructor, -use the $this->load->library function:: +use the ``$this->load->library()`` method:: $this->load->library('cart'); @@ -49,16 +49,16 @@ Adding an Item to The Cart ========================== To add an item to the shopping cart, simply pass an array with the -product information to the $this->cart->insert() function, as shown +product information to the ``$this->cart->insert()`` method, as shown below:: $data = array( - 'id' => 'sku_123ABC', - 'qty' => 1, - 'price' => 39.95, - 'name' => 'T-Shirt', - 'options' => array('Size' => 'L', 'Color' => 'Red') - ); + 'id' => 'sku_123ABC', + 'qty' => 1, + 'price' => 39.95, + 'name' => 'T-Shirt', + 'options' => array('Size' => 'L', 'Color' => 'Red') + ); $this->cart->insert($data); @@ -91,16 +91,16 @@ information in a table easier. :: $data = array( - 'id' => 'sku_123ABC', - 'qty' => 1, - 'price' => 39.95, - 'name' => 'T-Shirt', - 'coupon' => 'XMAS-50OFF' - ); + 'id' => 'sku_123ABC', + 'qty' => 1, + 'price' => 39.95, + 'name' => 'T-Shirt', + 'coupon' => 'XMAS-50OFF' + ); $this->cart->insert($data); -The insert() method will return the $rowid if you successfully insert a +The ``insert()`` method will return the $rowid if you successfully insert a single item. Adding Multiple Items to The Cart @@ -148,15 +148,15 @@ helper `. :: - + - - - - + + + + @@ -166,9 +166,9 @@ helper `. - - + - - + + + @@ -192,9 +192,9 @@ helper `. - - - + + +
QTYItem DescriptionItem PriceSub-TotalQTYItem DescriptionItem PriceSub-Total
$i.'[qty]', 'value' => $items['qty'], 'maxlength' => '3', 'size' => '5')); ?> - + $i.'[qty]', 'value' => $items['qty'], 'maxlength' => '3', 'size' => '5')); ?> + cart->has_options($items['rowid']) == TRUE): ?> @@ -182,9 +182,9 @@ helper `. - cart->format_number($items['price']); ?>$cart->format_number($items['subtotal']); ?>cart->format_number($items['price']); ?>$cart->format_number($items['subtotal']); ?>
 Total$cart->format_number($this->cart->total()); ?> Total$cart->format_number($this->cart->total()); ?>
@@ -205,8 +205,8 @@ Updating The Cart ================= To update the information in your cart, you must pass an array -containing the Row ID and quantity to the $this->cart->update() -function. +containing the Row ID and quantity to the ``$this->cart->update()`` +method:: .. note:: If the quantity is set to zero, the item will be removed from the cart. @@ -214,53 +214,52 @@ function. :: $data = array( - 'rowid' => 'b99ccdf16028f015540f341130b6d8ec', - 'qty' => 3 - ); + 'rowid' => 'b99ccdf16028f015540f341130b6d8ec', + 'qty' => 3 + ); $this->cart->update($data); // Or a multi-dimensional array $data = array( - array( - 'rowid' => 'b99ccdf16028f015540f341130b6d8ec', - 'qty' => 3 - ), - array( - 'rowid' => 'xw82g9q3r495893iajdh473990rikw23', - 'qty' => 4 - ), - array( - 'rowid' => 'fh4kdkkkaoe30njgoe92rkdkkobec333', - 'qty' => 2 - ) - ); + array( + 'rowid' => 'b99ccdf16028f015540f341130b6d8ec', + 'qty' => 3 + ), + array( + 'rowid' => 'xw82g9q3r495893iajdh473990rikw23', + 'qty' => 4 + ), + array( + 'rowid' => 'fh4kdkkkaoe30njgoe92rkdkkobec333', + 'qty' => 2 + ) + ); $this->cart->update($data); -You may also update any property you have previously -defined when inserting the item such as options, price -or other custom fields you defined. +You may also update any property you have previously defined when +inserting the item such as options, price or other custom fields. :: $data = array( - 'rowid' => 'b99ccdf16028f015540f341130b6d8ec', - 'qty' => 1, - 'price' => 49.95, - 'coupon' => NULL - ); + 'rowid' => 'b99ccdf16028f015540f341130b6d8ec', + 'qty' => 1, + 'price' => 49.95, + 'coupon' => NULL + ); $this->cart->update($data); What is a Row ID? ***************** -The row ID is a unique identifier that is -generated by the cart code when an item is added to the cart. The reason -a unique ID is created is so that identical products with different -options can be managed by the cart. +The row ID is a unique identifier that is generated by the cart code +when an item is added to the cart. The reason a unique ID is created +is so that identical products with different options can be managed +by the cart. For example, let's say someone buys two identical t-shirts (same product ID), but in different sizes. The product ID (and other attributes) will @@ -274,9 +273,9 @@ In nearly all cases, updating the cart will be something the user does via the "view cart" page, so as a developer, it is unlikely that you will ever have to concern yourself with the "row ID", other than making sure your "view cart" page contains this information in a hidden form -field, and making sure it gets passed to the update function when the -update form is submitted. Please examine the construction of the "view -cart" page above for more information. +field, and making sure it gets passed to the ``update()`` method when +the update form is submitted. Please examine the construction of the +"view cart" page above for more information. *************** @@ -374,7 +373,7 @@ Class Reference Returns TRUE (boolean) if a particular row in the cart contains options. This method is designed to be used in a loop with ``contents()``, since - you must pass the rowid to this function, as shown in the Displaying + you must pass the rowid to this method, as shown in the Displaying the Cart example above. .. method:: product_options([$row_id = '']) -- cgit v1.2.3-24-g4f1b From aef63e532bcede1d455bc27f0fc6f369ab74f203 Mon Sep 17 00:00:00 2001 From: Andrey Andreev Date: Thu, 13 Feb 2014 14:49:55 +0200 Subject: Add language translation support to CI_Pagination (#1589) --- user_guide_src/source/changelog.rst | 5 +++-- user_guide_src/source/libraries/pagination.rst | 8 ++++++++ 2 files changed, 11 insertions(+), 2 deletions(-) (limited to 'user_guide_src') diff --git a/user_guide_src/source/changelog.rst b/user_guide_src/source/changelog.rst index 029bf61cb..3bb88a779 100644 --- a/user_guide_src/source/changelog.rst +++ b/user_guide_src/source/changelog.rst @@ -367,11 +367,12 @@ Release Date: Not Released - :doc:`Pagination Library ` changes include: + - Deprecated usage of the "anchor_class" setting (use the new "attributes" setting instead). - Added method chaining support to ``initialize()`` method. - Added support for the anchor "rel" attribute. - Added support for setting custom attributes. - - Deprecated usage of the "anchor_class" setting (use the new "attributes" setting instead). - - Added $config['reuse_query_string'] to allow automatic repopulation of query string arguments, combined with normal URI segments. + - Added support for language translations of the *first_link*, *next_link*, *prev_link* and *last_link* values. + - Added ``$config['reuse_query_string']`` to allow automatic repopulation of query string arguments, combined with normal URI segments. - Removed the default `` `` from a number of the configuration variables. - :doc:`Profiler Library ` changes include: diff --git a/user_guide_src/source/libraries/pagination.rst b/user_guide_src/source/libraries/pagination.rst index ee12d9e6f..d8d31f8c5 100644 --- a/user_guide_src/source/libraries/pagination.rst +++ b/user_guide_src/source/libraries/pagination.rst @@ -165,6 +165,8 @@ $config['first_link'] = 'First'; The text you would like shown in the "first" link on the left. If you do not want this link rendered, you can set its value to FALSE. +.. note:: This value can also be translated via a language file. + $config['first_tag_open'] = '
'; ==================================== @@ -185,6 +187,8 @@ $config['last_link'] = 'Last'; The text you would like shown in the "last" link on the right. If you do not want this link rendered, you can set its value to FALSE. +.. note:: This value can also be translated via a language file. + $config['last_tag_open'] = '
'; =================================== @@ -205,6 +209,8 @@ $config['next_link'] = '>'; The text you would like shown in the "next" page link. If you do not want this link rendered, you can set its value to FALSE. +.. note:: This value can also be translated via a language file. + $config['next_tag_open'] = '
'; =================================== @@ -225,6 +231,8 @@ $config['prev_link'] = '<'; The text you would like shown in the "previous" page link. If you do not want this link rendered, you can set its value to FALSE. +.. note:: This value can also be translated via a language file. + $config['prev_tag_open'] = '
'; =================================== -- cgit v1.2.3-24-g4f1b From b1616b8c3370d59135275b6945ed1b80cfe99653 Mon Sep 17 00:00:00 2001 From: Andrey Andreev Date: Thu, 13 Feb 2014 15:12:43 +0200 Subject: Fix #2364 --- user_guide_src/source/changelog.rst | 1 + 1 file changed, 1 insertion(+) (limited to 'user_guide_src') diff --git a/user_guide_src/source/changelog.rst b/user_guide_src/source/changelog.rst index 3bb88a779..d4f882064 100644 --- a/user_guide_src/source/changelog.rst +++ b/user_guide_src/source/changelog.rst @@ -710,6 +710,7 @@ Bug fixes for 3.0 - Fixed a bug (#2856) - ODBC method ``affected_rows()`` passed an incorrect value to ``odbc_num_rows()``. - Fixed a bug (#43) :doc:`Image Manipulation Library ` method ``text_watermark()`` didn't properly determine watermark placement. - Fixed a bug where :doc:`HTML Table Library ` ignored its *auto_heading* setting if headings were not already set. +- Fixed a bug (#2364) - :doc:`Pagination Library ` appended the query string (if used) multiple times when there are successive calls to ``create_links()`` with no ``initialize()`` in between them. Version 2.1.4 ============= -- cgit v1.2.3-24-g4f1b From 81f036753272391360ba5b64e6dd93c4101a8733 Mon Sep 17 00:00:00 2001 From: Andrey Andreev Date: Thu, 13 Feb 2014 17:57:41 +0200 Subject: [ci skip] Add compatibility functions documentation + Sphinx build fixes for Cart --- user_guide_src/source/changelog.rst | 2 +- .../source/general/compatibility_functions.rst | 157 +++++++++++++++++++++ user_guide_src/source/general/index.rst | 1 + user_guide_src/source/libraries/cart.rst | 42 +++--- 4 files changed, 180 insertions(+), 22 deletions(-) create mode 100644 user_guide_src/source/general/compatibility_functions.rst (limited to 'user_guide_src') diff --git a/user_guide_src/source/changelog.rst b/user_guide_src/source/changelog.rst index d4f882064..ca31669e8 100644 --- a/user_guide_src/source/changelog.rst +++ b/user_guide_src/source/changelog.rst @@ -506,7 +506,7 @@ Release Date: Not Released - ``UTF8_ENABLED`` now requires only one of `Multibyte String `_ or `iconv `_ to be available instead of both. - Changed method ``clean_string()`` to utilize ``mb_convert_encoding()`` if it is available but ``iconv()`` is not. - - Added compatibility layers for PHP's `mbstring `_ (limited support) and `password `_ extensions. + - Added `compatibility layers ` for PHP's `mbstring `_ (limited support) and `password `_ extensions. - Removed ``CI_CORE`` boolean constant from *CodeIgniter.php* (no longer Reactor and Core versions). - Log Library will now try to create the **log_path** directory if it doesn't exist. - Added support for HTTP-Only cookies with new config option *cookie_httponly* (default FALSE). diff --git a/user_guide_src/source/general/compatibility_functions.rst b/user_guide_src/source/general/compatibility_functions.rst new file mode 100644 index 000000000..e025d2aa3 --- /dev/null +++ b/user_guide_src/source/general/compatibility_functions.rst @@ -0,0 +1,157 @@ +####################### +Compatibility Functions +####################### + +CodeIgniter provides a set of compatibility functions that enable +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 +PHP setup doesn't offer them natively. + +.. note:: Much like the `common functions `, the + compatibility functions are always available, as long as + their dependancies are met. + +.. contents:: + :local: + +.. raw:: html + +
+ +**************** +Password Hashing +**************** + +This set of compatibility functions offers a "backport" of PHP's +standard `Password Hashing extension `_ +that is otherwise available only since PHP 5.5. + +Dependancies +============ + +- PHP 5.3.7 +- ``CRYPT_BLOWFISH`` support for ``crypt()`` + +Constants +========= + +- ``PASSWORD_BCRYPT`` +- ``PASSWORD_DEFAULT`` + +Function reference +================== + +.. function:: password_get_info($hash) + + :param string $hash: Password hash + :returns: Information about the hashed password + :rtype: array + + For more information, please refer to the `PHP manual for + password_get_info() `_. + +.. function:: password_hash($password, $algo[, $options = array()]) + + :param string $password: Plain-text password + :param int $algo: Hashing algorithm + :param array $options: Hashing options + :returns: Hashed password or FALSE on failure + :rtype: string + + For more information, please refer to the `PHP manual for + password_hash() `_. + + .. note:: Unless you provide your own (and valid) salt, this function + has a further dependancy on an available CSPRNG source. Each + of the following would satisfy that: + - ``mcrypt_create_iv()`` with ``MCRYPT_DEV_URANDOM`` + - ``openssl_random_pseudo_bytes()`` + - /dev/arandom + - /dev/urandom + +.. function:: password_needs_rehash() + + :param string $hash: Password hash + :param int $algo: Hashing algorithm + :param array $options: Hashing options + :returns: TRUE if the hash should be rehashed to match the given algorithm and options, FALSE otherwise + :rtype: bool + + For more information, please refer to the `PHP manual for + password_needs_rehash() `_. + +.. function:: password_verify($password, $hash) + + :param string $password: Plain-text password + :param string $hash: Password hash + :returns: TRUE if the password matches the hash, FALSE if not + :rtype: bool + + For more information, please refer to the `PHP manual for + password_verify() `_. + +**************** +Multibyte String +**************** + +This set of compatibility functions offers limited support for PHP's +`Multibyte String extension `_. Because of +the limited alternative solutions, only a few functions are available. + +.. note:: When a character set parameter is ommited, + ``$config['charset']`` will be used. + +Dependancies +============ + +- `iconv `_ extension + +.. important:: This dependancy 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 + extension, use the ``MB_ENABLED`` constant. + +Function reference +================== + +.. function:: mb_strlen($str[, $encoding = NULL]) + + :param string $str: Input string + :param string $encoding: Character set + :returns: Number of characters in the input string or FALSE on failure + :rtype: string + + For more information, please refer to the `PHP manual for + mb_strlen() `_. + +.. function:: mb_strpos($haystack, $needle[, $offset = 0[, $encoding = NULL]]) + + :param string $haystack: String to search in + :param string $needle: Part of string to search for + :param int $offset: Search offset + :param string $encoding: Character set + :returns: Numeric character position of where $needle was found or FALSE if not found + :rtype: mixed + + For more information, please refer to the `PHP manual for + mb_strpos() `_. + +.. function:: mb_substr($str, $start[, $length = NULL[, $encoding = NULL]]) + + :param string $str: Input string + :param int $start: Position of first character + :param int $length: Maximum number of characters + :param string $encoding: Character set + :returns: Portion of $str specified by $start and $length or FALSE on failure + :rtype: string + + For more information, please refer to the `PHP manual for + mb_substr() `_. \ No newline at end of file diff --git a/user_guide_src/source/general/index.rst b/user_guide_src/source/general/index.rst index 2bc684a1d..195c4a98a 100644 --- a/user_guide_src/source/general/index.rst +++ b/user_guide_src/source/general/index.rst @@ -20,6 +20,7 @@ General Topics hooks autoloader common_functions + compatibility_functions routing errors Caching diff --git a/user_guide_src/source/libraries/cart.rst b/user_guide_src/source/libraries/cart.rst index 8a473b49d..d7d495967 100644 --- a/user_guide_src/source/libraries/cart.rst +++ b/user_guide_src/source/libraries/cart.rst @@ -114,26 +114,26 @@ same page. :: $data = array( - array( - 'id' => 'sku_123ABC', - 'qty' => 1, - 'price' => 39.95, - 'name' => 'T-Shirt', - 'options' => array('Size' => 'L', 'Color' => 'Red') - ), - array( - 'id' => 'sku_567ZYX', - 'qty' => 1, - 'price' => 9.95, - 'name' => 'Coffee Mug' - ), - array( - 'id' => 'sku_965QRS', - 'qty' => 1, - 'price' => 29.95, - 'name' => 'Shot Glass' - ) - ); + array( + 'id' => 'sku_123ABC', + 'qty' => 1, + 'price' => 39.95, + 'name' => 'T-Shirt', + 'options' => array('Size' => 'L', 'Color' => 'Red') + ), + array( + 'id' => 'sku_567ZYX', + 'qty' => 1, + 'price' => 9.95, + 'name' => 'Coffee Mug' + ), + array( + 'id' => 'sku_965QRS', + 'qty' => 1, + 'price' => 29.95, + 'name' => 'Shot Glass' + ) + ); $this->cart->insert($data); @@ -206,7 +206,7 @@ Updating The Cart To update the information in your cart, you must pass an array containing the Row ID and quantity to the ``$this->cart->update()`` -method:: +method. .. note:: If the quantity is set to zero, the item will be removed from the cart. -- cgit v1.2.3-24-g4f1b From cd74d36ae1ac34c25271b5ff81cc2fd8df099724 Mon Sep 17 00:00:00 2001 From: Andrey Andreev Date: Sat, 15 Feb 2014 21:44:02 +0200 Subject: Rename CI_Utf8::_is_ascii() to is_ascii() and make it public No reason for it to be protected. --- user_guide_src/source/changelog.rst | 1 + 1 file changed, 1 insertion(+) (limited to 'user_guide_src') diff --git a/user_guide_src/source/changelog.rst b/user_guide_src/source/changelog.rst index ca31669e8..bda4cbab4 100644 --- a/user_guide_src/source/changelog.rst +++ b/user_guide_src/source/changelog.rst @@ -505,6 +505,7 @@ Release Date: Not Released - ``UTF8_ENABLED`` now requires only one of `Multibyte String `_ or `iconv `_ to be available instead of both. - Changed method ``clean_string()`` to utilize ``mb_convert_encoding()`` if it is available but ``iconv()`` is not. + - Renamed method ``_is_ascii()`` to ``is_ascii()`` and made it public. - Added `compatibility layers ` for PHP's `mbstring `_ (limited support) and `password `_ extensions. - Removed ``CI_CORE`` boolean constant from *CodeIgniter.php* (no longer Reactor and Core versions). -- cgit v1.2.3-24-g4f1b