summaryrefslogtreecommitdiffstats
path: root/user_guide/general
diff options
context:
space:
mode:
Diffstat (limited to 'user_guide/general')
-rw-r--r--user_guide/general/controllers.html20
-rw-r--r--user_guide/general/views.html8
2 files changed, 14 insertions, 14 deletions
diff --git a/user_guide/general/controllers.html b/user_guide/general/controllers.html
index cdc4b3ee5..56a1145ad 100644
--- a/user_guide/general/controllers.html
+++ b/user_guide/general/controllers.html
@@ -96,7 +96,7 @@ Controllers
<textarea class="textarea" style="width:100%" cols="50" rows="10">
&lt;?php
-class Blog extends Controller {
+class Blog extends CI_Controller {
function index()
{
@@ -119,7 +119,7 @@ class Blog extends Controller {
<p>Note: Class names must start with an uppercase letter. In other words, this is valid:</p>
<code>&lt;?php<br />
-class <var>Blog</var> extends Controller {<br />
+class <var>Blog</var> extends CI_Controller {<br />
<br />
}<br />
?&gt;</code>
@@ -127,7 +127,7 @@ class <var>Blog</var> extends Controller {<br />
<p>This is <strong>not</strong> valid:</p>
<code>&lt;?php<br />
-class <var>blog</var> extends Controller {<br />
+class <var>blog</var> extends CI_Controller {<br />
<br />
}<br />
?&gt;</code>
@@ -151,7 +151,7 @@ class <var>blog</var> extends Controller {<br />
<textarea class="textarea" style="width:100%" cols="50" rows="15">
&lt;?php
-class Blog extends Controller {
+class Blog extends CI_Controller {
function index()
{
@@ -185,7 +185,7 @@ class Blog extends Controller {
<code>
&lt;?php<br />
-class Products extends Controller {<br />
+class Products extends CI_Controller {<br />
<br />
&nbsp;&nbsp;&nbsp;&nbsp;function shoes($sandals, $id)<br />
&nbsp;&nbsp;&nbsp;&nbsp;{<br />
@@ -330,7 +330,7 @@ called if the URL contains only the sub-folder. Simply name your default contro
<p>If you intend to use a constructor in any of your Controllers, you <strong>MUST</strong> place the following line of code in it:</p>
-<code>parent::Controller();</code>
+<code>parent::CI_Controller();</code>
<p>The reason this line is necessary is because your local constructor will be overriding the one in the parent controller class so we need to manually call it.</p>
@@ -339,11 +339,11 @@ called if the URL contains only the sub-folder. Simply name your default contro
<code>
&lt;?php<br />
-class <kbd>Blog</kbd> extends Controller {<br />
+class <kbd>Blog</kbd> extends CI_Controller {<br />
<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;function <kbd>Blog()</kbd><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{<br />
-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<var>parent::Controller();</var><br />
+&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<var>parent::CI_Controller();</var><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<br />
}<br />
?&gt;</code>
@@ -352,11 +352,11 @@ class <kbd>Blog</kbd> extends Controller {<br />
<code>
&lt;?php<br />
-class <kbd>Blog</kbd> extends Controller {<br />
+class <kbd>Blog</kbd> extends CI_Controller {<br />
<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;function <kbd>__construct()</kbd><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{<br />
-&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<var>parent::Controller();</var><br />
+&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<var>parent::CI_Controller();</var><br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<br />
}<br />
?&gt;</code>
diff --git a/user_guide/general/views.html b/user_guide/general/views.html
index 8f317109e..228eb64b5 100644
--- a/user_guide/general/views.html
+++ b/user_guide/general/views.html
@@ -98,7 +98,7 @@ you should do so before continuing.</p>
<textarea class="textarea" style="width:100%" cols="50" rows="10">
&lt;?php
-class Blog extends Controller {
+class Blog extends CI_Controller {
function index()
{
@@ -117,7 +117,7 @@ class Blog extends Controller {
<p>CodeIgniter will intelligently handle multiple calls to $this-&gt;load-&gt;view from within a controller. If more than one call happens they will be appended together. For example, you may wish to have a header view, a menu view, a content view, and a footer view. That might look something like this:</p>
<p><code>&lt;?php<br />
<br />
-class Page extends Controller {<br /><br />
+class Page extends CI_Controller {<br /><br />
&nbsp;&nbsp;&nbsp;function index()<br />
&nbsp;&nbsp;&nbsp;{<br />
@@ -163,7 +163,7 @@ $this->load->view('blogview', <var>$data</var>);</code>
<textarea class="textarea" style="width:100%" cols="50" rows="14">
&lt;?php
-class Blog extends Controller {
+class Blog extends CI_Controller {
function index()
{
@@ -203,7 +203,7 @@ pull data from your database it will typically be in the form of a multi-dimensi
<textarea class="textarea" style="width:100%" cols="50" rows="17">
&lt;?php
-class Blog extends Controller {
+class Blog extends CI_Controller {
function index()
{