summaryrefslogtreecommitdiffstats
path: root/user_guide
diff options
context:
space:
mode:
authoradmin <devnull@localhost>2006-09-22 01:50:23 +0200
committeradmin <devnull@localhost>2006-09-22 01:50:23 +0200
commitc1fa07415179d63762f1a22f0f74660a8034707f (patch)
tree8eb458e58d1c221dfa01f2adc0a97cf084bcc805 /user_guide
parentfc6d9079f9f47d7474c65d6bec2aa7305a35df64 (diff)
Diffstat (limited to 'user_guide')
-rw-r--r--user_guide/general/changelog.html14
-rw-r--r--user_guide/general/controllers.html53
-rw-r--r--user_guide/general/requirements.html2
-rw-r--r--user_guide/libraries/calendar.html2
4 files changed, 48 insertions, 23 deletions
diff --git a/user_guide/general/changelog.html b/user_guide/general/changelog.html
index 23d382fcb..8930ee023 100644
--- a/user_guide/general/changelog.html
+++ b/user_guide/general/changelog.html
@@ -64,18 +64,18 @@ Change Log
<h2>Version 1.4.1</h2>
-<p>Release Date: September 25, 2006</p>
+<p>Release Date: September 21, 2006</p>
<ul>
<li>Added a new feature that passes URI segments directly to your function calls as parameters. See the <a href="controllers.html">Controllers</a> page for more info.</li>
-<li>Added several new functions in the <a href="../libraries/uri.html">URI Class</a> to let you retrieve and manipulate Re-routed URI segments. Previously, the URI class did not permit you to access any re-routed URI segments when you used the <a href="routing.html">URI Routing</a> feature. Now it does.</li>
-<li>Updated plugins, helpers, and language classes to allow your "application" folder to contain its own plugins, helpers, and language folders. If your application folder contains any of these resources, when you load them CI will look first in your local application folder. If not found, it instead looks in the global folders.</li>
-<li>Added <a href="../helpers/inflector_helper.html">Inflector helper</a>.</li>
-<li>Added element() function in the <a href="../helpers/array_helper.html">array helper</a>.</li>
+<li>Added support for a function named <dfn>_output()</dfn>, which when used in your controllers will received the final rendered output from the output class. More info in the <a href="controllers.html">Controllers</a> page.</li>
+<li>Added several new functions in the <a href="../libraries/uri.html">URI Class</a> to let you retrieve and manipulate URI segments that have been re-routed using the <a href="routing.html">URI Routing</a> feature. Previously, the URI class did not permit you to access any re-routed URI segments, but now it does.</li>
<li>Added <a href="../libraries/output.html">$this->output->set_header()</a> function, which allows you to set server headers.</li>
-<li>Added RAND() to active record orderby() function.</li>
+<li>Updated plugins, helpers, and language classes to allow your <dfn>application</dfn> folder to contain its own plugins, helpers, and language folders. Previously they were always treated as global for your entire installation. If your application folder contains any of these resources they will be used <em>instead</em> the global ones.</li>
+<li>Added <a href="../helpers/inflector_helper.html">Inflector helper</a>.</li>
+<li>Added <dfn>element()</dfn> function in the <a href="../helpers/array_helper.html">array helper</a>.</li>
+<li>Added <dfn>RAND()</dfn> to active record <dfn>orderby()</dfn> function.</li>
<li>Added <dfn>delete_cookie()</dfn> and <dfn>get_cookie()</dfn> to <a href="../helpers/cookie_helper.html">Cookie helper</a>, even though the input class has a cookie fetching function.</li>
-<li>Added German language pack.</li>
<li>Added Oracle database driver (still undergoing testing so it might have some bugs).</li>
<li>Added the ability to combine pseudo-variables and php variables in the template parser class.</li>
<li>Removed the is_numeric test from the db->escape() function.</li>
diff --git a/user_guide/general/controllers.html b/user_guide/general/controllers.html
index cb38a4abc..5c51f8ff0 100644
--- a/user_guide/general/controllers.html
+++ b/user_guide/general/controllers.html
@@ -70,9 +70,10 @@ Controllers
<li><a href="#hello">Hello World</a></li>
<li><a href="#functions">Functions</a></li>
<li><a href="#passinguri">Passing URI Segments to Your Functions</a></li>
+<li><a href="#default">Defining a Default Controller</a></li>
<li><a href="#remapping">Remapping Function Calls</a></li>
+<li><a href="#output">Controlling Output Data</a></li>
<li><a href="#private">Private Functions</a></li>
-<li><a href="#default">Defining a Default Controller</a></li>
<li><a href="#subfolders">Organizing Controllers into Sub-folders</a></li>
<li><a href="#constructors">Class Constructors</a></li>
<li><a href="#reserved">Reserved Function Names</a></li>
@@ -204,6 +205,19 @@ class Products extends Controller {<br />
passed to your function will be the re-routed ones.</p>
+<a name="default"></a>
+<h2>Defining a Default Controller</h2>
+
+<p>Code Igniter can be told to load a default controller when a URI is not present,
+as will be the case when only your site root URL is requested. To specify a default controller, open
+your <dfn>application/config/routes.php</dfn> file and set this variable:</p>
+
+<code>$route['default_controller'] = '<var>Blog</var>';</code>
+
+<p>Where <var>Blog</var> is the name of the controller class you want used. If you now load your main index.php file without
+specifying any URI segments you'll see your Hello World message by default.</p>
+
+
<a name="remapping"></a>
<h2>Remapping Function Calls</h2>
@@ -237,9 +251,33 @@ allowing you to define your own function routing rules.</p>
+
+<a name="output"></a>
+<h2>Processing Output</h2>
+
+<p>Code Igniter has an output class that takes care of sending your final rendered data to the web browser automatically. More information on this can be found in the
+<a href="views.html">Views</a> and <a href="../libraries/output.html">Output class</a> pages. In some cases, however, you might want to control
+how the output gets sent to the browser, or you might want to post process the finalized data in some way. Code Igniter permits you to
+add a function named <dfn>_output()</dfn> to your controller that will receive the finalized output data.
+
+<p class="important"><strong>Important:</strong>&nbsp; If your controller contains a function named <kbd>_output()</kbd>, it will <strong>always</strong>
+be called by the output class instead of echoing the finalized data directly. The first parameter of the function will contain the finalized output.</p>
+
+<p>Here is an example:</p>
+
+<code>
+function _output($output)<br />
+{<br />
+&nbsp;&nbsp;&nbsp;&nbsp;echo $output;<br />
+}</code>
+
+<p>Please note that your <dfn>_output()</dfn> function will receive the data in its finalized form - including rendered benchmark and memory usage data,
+so if you are using this feature the page execution timer might not be perfectly accurate.</p>
+
<a name="private"></a>
<h2>Private Functions</h2>
+
<p>In some cases you may want certain functions hidden from public access. To make a function private, simply add an
underscore as the name prefix and it will not be served via a URL request. For example, if you were to have a function like this:</p>
@@ -255,19 +293,6 @@ function _utility()<br />
-<a name="default"></a>
-<h2>Defining a Default Controller</h2>
-
-<p>Code Igniter can be told to load a default controller when a URI is not present,
-as will be the case when only your site root URL is requested. To specify a default controller, open
-your <dfn>application/config/routes.php</dfn> file and set this variable:</p>
-
-<code>$route['default_controller'] = '<var>Blog</var>';</code>
-
-<p>Where <var>Blog</var> is the name of the controller class you want used. If you now load your main index.php file without
-specifying any URI segments you'll see your Hello World message by default.</p>
-
-
<a name="subfolders"></a>
<h2>Organizing Your Controllers into Sub-folders</h2>
diff --git a/user_guide/general/requirements.html b/user_guide/general/requirements.html
index 8a1d7c6fb..2694723bd 100644
--- a/user_guide/general/requirements.html
+++ b/user_guide/general/requirements.html
@@ -64,7 +64,7 @@ Server Requirements
<ul>
<li><a href="http://www.php.net/">PHP</a> version 4.3.2 or newer</li>
- <li>A Database. Supported databases are MySQL, MySQLi, MS SQL, Postgre, SQLite, and ODBC</li>
+ <li>A Database. Supported databases are MySQL, MySQLi, MS SQL, Postgre, Oracle, SQLite, and ODBC</li>
</ul>
diff --git a/user_guide/libraries/calendar.html b/user_guide/libraries/calendar.html
index b6830b7ed..f8cd2ff21 100644
--- a/user_guide/libraries/calendar.html
+++ b/user_guide/libraries/calendar.html
@@ -201,7 +201,7 @@ $prefs['template'] = '<br /><br />
&nbsp;&nbsp;&nbsp;<dfn>{cal_cell_blank}</dfn><var>&amp;nbsp;</var><dfn>{/cal_cell_blank}</dfn><br />
<br />
&nbsp;&nbsp;&nbsp;<dfn>{cal_cell_end}</dfn><var>&lt;/td></var><dfn>{/cal_cell_end}</dfn><br />
-&nbsp;&nbsp;&nbsp;<dfn>{cal_row_end}</dfn><var>&lt;tr></var><dfn>{/cal_row_end}</dfn><br />
+&nbsp;&nbsp;&nbsp;<dfn>{cal_row_end}</dfn><var>&lt;/tr></var><dfn>{/cal_row_end}</dfn><br />
<br />
&nbsp;&nbsp;&nbsp;<dfn>{table_close}</dfn><var>&lt;/table></var><dfn>{/table_close}</dfn><br />
';<br />