summaryrefslogtreecommitdiffstats
path: root/user_guide/general
diff options
context:
space:
mode:
authorDerek Allard <derek.allard@ellislab.com>2008-04-04 14:26:46 +0200
committerDerek Allard <derek.allard@ellislab.com>2008-04-04 14:26:46 +0200
commit1ea127ae8a8026af7679526af06ff297d5104104 (patch)
treef4e4af79cdfaaa2efb883f2305c8950a85c55c20 /user_guide/general
parent72c82c1de6efb25a529f3206800de7ddd70ea83e (diff)
doc fixes
Diffstat (limited to 'user_guide/general')
-rw-r--r--user_guide/general/helpers.html5
-rw-r--r--user_guide/general/hooks.html59
2 files changed, 21 insertions, 43 deletions
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
<p>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 <a href="../general/controllers.html">controller</a> and <a href="../general/views.html">views</a>.</p>
-<p>Helpers are typically stored in your <dfn>system/helpers</dfn> directory. Alternately you can create a folder called <kbd>helpers</kbd> inside
-your <kbd>application</kbd> folder and store them there. CodeIgniter will look first in your <dfn>system/application/helpers</dfn>
+<p>Helpers are typically stored in your <dfn>system/helpers</dfn>, or <dfn>system/application/helpers </dfn>directory. CodeIgniter will look first in your <dfn>system/application/helpers</dfn>
directory. If the directory does not exist or the specified helper is not located there CI will instead look in your global
<dfn>system/helpers</dfn> folder.</p>
@@ -149,7 +148,7 @@ function any_in_array($needle, $haystack)<br />
function random_element($array)<br />
{<br />
&nbsp;&nbsp;&nbsp;&nbsp;shuffle($array);<br />
-&nbsp;&nbsp;&nbsp;&nbsp;return array_pop();<br />
+&nbsp;&nbsp;&nbsp;&nbsp;return array_pop($array);<br />
}<br />
</code>
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']<kbd>[]</kbd> = array(<br />
<code>$hook['pre_controller']<kbd>[]</kbd></code>
-<p>This permits you to the same hook point with multiple scripts. The order you define your array will be the execution order.</p>
+<p>This permits you to have the same hook point with multiple scripts. The order you define your array will be the execution order.</p>
<h2>Hook Points</h2>
@@ -130,45 +130,24 @@ $hook['pre_controller']<kbd>[]</kbd> = array(<br />
<p>The following is a list of available hook points.</p>
<ul>
-
-<li><strong>pre_system</strong><br />
-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.</li>
-
-<li><strong>pre_controller</strong><br />
-Called immediately prior to any of your controllers being called. All base classes, routing, and security checks have been done.</li>
-
-<li><strong>post_controller_constructor</strong><br />
-Called immediately after your controller is instantiated, but prior to any method calls happening.</li>
-
-<li><strong>post_controller</strong><br />
-Called immediately after your controller is fully executed.</li>
-
-<li><strong>display_override</strong><br />
-Overrides the <dfn>_display()</dfn> 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 <dfn>$this->output->get_output()</dfn></li>
-
-<li><strong>cache_override</strong><br />
-Enables you to call your own function instead of the <dfn>_display_cache()</dfn> function in the output class. This permits you to use your own cache display mechanism.</li>
-
-<li><strong>scaffolding_override</strong><br />
-Permits a scaffolding request to trigger your own script instead.</li>
-
-<li><strong>post_system</strong><br />
-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.</li>
-
-
-</ul>
-
-
-
-
-
-
-
-
-
-
-
+ <li><strong>pre_system</strong><br />
+ 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.</li>
+ <li><strong>pre_controller</strong><br />
+ Called immediately prior to any of your controllers being called. All base classes, routing, and security checks have been done.</li>
+ <li><strong>post_controller_constructor</strong><br />
+ Called immediately after your controller is instantiated, but prior to any method calls happening.</li>
+ <li><strong>post_controller</strong><br />
+ Called immediately after your controller is fully executed.</li>
+ <li><strong>display_override</strong><br />
+ Overrides the <dfn>_display()</dfn> 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 <dfn>$this->output->get_output()</dfn></li>
+ <li><strong>cache_override</strong><br />
+ Enables you to call your own function instead of the <dfn>_display_cache()</dfn> function in the output class. This permits you to use your own cache display mechanism.</li>
+ <li><strong>scaffolding_override</strong><br />
+ Permits a scaffolding request to trigger your own script instead.</li>
+ <li><strong>post_system</strong><br />
+ 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.</li>
+ </ul>
</div>
<!-- END CONTENT -->