From 1ea127ae8a8026af7679526af06ff297d5104104 Mon Sep 17 00:00:00 2001 From: Derek Allard Date: Fri, 4 Apr 2008 12:26:46 +0000 Subject: doc fixes --- user_guide/general/helpers.html | 5 ++-- user_guide/general/hooks.html | 59 +++++++++++++---------------------------- 2 files changed, 21 insertions(+), 43 deletions(-) (limited to 'user_guide/general') diff --git a/user_guide/general/helpers.html b/user_guide/general/helpers.html index 063ef720c..5569d9834 100644 --- a/user_guide/general/helpers.html +++ b/user_guide/general/helpers.html @@ -69,8 +69,7 @@ Each helper function performs one specific task, with no dependence on other fun

CodeIgniter does not load Helper Files by default, so the first step in using a Helper is to load it. Once loaded, it becomes globally available in your controller and views.

-

Helpers are typically stored in your system/helpers directory. Alternately you can create a folder called helpers inside -your application folder and store them there. CodeIgniter will look first in your system/application/helpers +

Helpers are typically stored in your system/helpers, or system/application/helpers directory. CodeIgniter will look first in your system/application/helpers directory. If the directory does not exist or the specified helper is not located there CI will instead look in your global system/helpers folder.

@@ -149,7 +148,7 @@ function any_in_array($needle, $haystack)
function random_element($array)
{
    shuffle($array);
-    return array_pop();
+    return array_pop($array);
}
diff --git a/user_guide/general/hooks.html b/user_guide/general/hooks.html index 14e28d47f..11acc043e 100644 --- a/user_guide/general/hooks.html +++ b/user_guide/general/hooks.html @@ -122,7 +122,7 @@ $hook['pre_controller'][] = array(
$hook['pre_controller'][] -

This permits you to the same hook point with multiple scripts. The order you define your array will be the execution order.

+

This permits you to have the same hook point with multiple scripts. The order you define your array will be the execution order.

Hook Points

@@ -130,45 +130,24 @@ $hook['pre_controller'][] = array(

The following is a list of available hook points.

- - - - - - - - - - - +
  • pre_system
    + Called very early during system execution. Only the benchmark and hooks class have been loaded at this point. No routing or other processes have happened.
  • +
  • pre_controller
    + Called immediately prior to any of your controllers being called. All base classes, routing, and security checks have been done.
  • +
  • post_controller_constructor
    + Called immediately after your controller is instantiated, but prior to any method calls happening.
  • +
  • post_controller
    + Called immediately after your controller is fully executed.
  • +
  • display_override
    + Overrides the _display() function, used to send the finalized page to the web browser at the end of system execution. This permits you to + use your own display methodology. Note that the finalized data will be available by calling $this->output->get_output()
  • +
  • cache_override
    + Enables you to call your own function instead of the _display_cache() function in the output class. This permits you to use your own cache display mechanism.
  • +
  • scaffolding_override
    + Permits a scaffolding request to trigger your own script instead.
  • +
  • post_system
    + Called after the final rendered page is sent to the browser, at the end of system execution after the finalized data is sent to the browser.
  • + -- cgit v1.2.3-24-g4f1b