From 885b0343036695ad673fc24ba7682fc155c54036 Mon Sep 17 00:00:00 2001 From: admin Date: Thu, 21 Sep 2006 05:36:15 +0000 Subject: --- user_guide/general/changelog.html | 3 +++ user_guide/helpers/cookie_helper.html | 26 +++++++++++++++++++++++- user_guide/libraries/database/active_record.html | 2 +- 3 files changed, 29 insertions(+), 2 deletions(-) (limited to 'user_guide') diff --git a/user_guide/general/changelog.html b/user_guide/general/changelog.html index ca04b140c..80ffe7a4e 100644 --- a/user_guide/general/changelog.html +++ b/user_guide/general/changelog.html @@ -71,10 +71,13 @@ Change Log
  • Added Inflector helper.
  • Added element() function in the array helper.
  • Added $this->output->set_header() function, which allows you to set server headers.
  • +
  • Added RAND() to active record orderby() function.
  • +
  • Added delete_cookie() and get_cookie() to Cookie helper, even though the input class has a cookie fetching function.
  • Removed the is_numeric test from the db->escape() function.
  • Fixed a MySQLi bug that was causing error messages not to contain proper errror data.
  • Fixed a bug in the email class which was causing it to ignore explicitly set alternative headers.
  • Fixed a bug that was causing a PHP error when the Exceptions class was called within the _get_config() function.
  • +
  • Fixed an oversight in the cookie helper in which the config file cookie settings were not being honored.
  • Added some code to allow email attachments to be reset when sending batches of email.
  • Deprecated the following database functions: $this->db->smart_escape_str() and $this->db->fields().
  • diff --git a/user_guide/helpers/cookie_helper.html b/user_guide/helpers/cookie_helper.html index 3e89df74d..9c17cdd5c 100644 --- a/user_guide/helpers/cookie_helper.html +++ b/user_guide/helpers/cookie_helper.html @@ -76,7 +76,7 @@ Cookie Helper

    set_cookie()

    Sets a cookie containing the values you specify. There are two ways to pass information this function so that a cookie can be set: -Arrray Method, and Discreet Parameters:

    +Array Method, and Discreet Parameters:

    Array Method

    @@ -112,6 +112,30 @@ zero the cookie will only last as long as the browser is open.

    set_cookie($name, $value, $expire, $domain, $path, $prefix); +

    get_cookie()

    + +

    Lets you fetch a cookie. The first parameter will contain the name of the cookie you are looking for:

    + +get_cookie('some_cookie'); + +

    The function returns FALSE (boolean) if the item you are attempting to retrieve does not exist.

    + +

    The second optional parameter lets you run the data through the XSS filter. It's enabled by setting the second parameter to boolean TRUE;

    + +get_cookie('some_cookie', TRUE); + + + +

    delete_cookie()

    + +

    Lets you delete a cookie. Unless you've set a custom path or other values, only the name of the cookie is needed:

    + +delete_cookie("name"); + +

    This function is otherwise identical to set_cookie(), except that it does not have the value and expiration parameters. You can submit an array +of values in the first parameter or you can set discreet parameters.

    + +delete_cookie($name, $domain, $path, $prefix) diff --git a/user_guide/libraries/database/active_record.html b/user_guide/libraries/database/active_record.html index 793f41f1e..b45c5d14e 100644 --- a/user_guide/libraries/database/active_record.html +++ b/user_guide/libraries/database/active_record.html @@ -354,7 +354,7 @@ $this->db->orlike('body', $match);

    $this->db->orderby();

    Lets you set an ORDER BY clause. The first parameter contains the name of the column you would like to order by. -The second parameter lets you set the direction of the result. Options are asc or desc

    +The second parameter lets you set the direction of the result. Options are asc or desc or RAND()

    $this->db->orderby("title", "desc");

    // Produces: ORDER BY title DESC -- cgit v1.2.3-24-g4f1b