summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--system/core/CodeIgniter.php14
-rw-r--r--system/core/Router.php2
-rw-r--r--system/libraries/Cache/drivers/Cache_apc.php2
-rw-r--r--system/libraries/Cache/drivers/Cache_memcached.php2
-rw-r--r--user_guide/database/utilities.html4
-rw-r--r--user_guide/libraries/javascript.html9
6 files changed, 22 insertions, 11 deletions
diff --git a/system/core/CodeIgniter.php b/system/core/CodeIgniter.php
index 2d3f24958..0414ffbf1 100644
--- a/system/core/CodeIgniter.php
+++ b/system/core/CodeIgniter.php
@@ -80,7 +80,7 @@
{
get_config(array('subclass_prefix' => $assign_to_config['subclass_prefix']));
}
-
+
/*
* ------------------------------------------------------
* Set a liberal script execution time limit
@@ -289,7 +289,17 @@
// methods, so we'll use this workaround for consistent behavior
if ( ! in_array(strtolower($method), array_map('strtolower', get_class_methods($CI))))
{
- show_404("{$class}/{$method}");
+ // Check and see if we are using a 404 override and use it.
+ if ( ! empty($RTR->routes['404_override']))
+ {
+ $x = explode('/', $RTR->routes['404_override']);
+ $class = $x[0];
+ $method = (isset($x[1]) ? $x[1] : 'index');
+ }
+ else
+ {
+ show_404("{$class}/{$method}");
+ }
}
// Call the requested method.
diff --git a/system/core/Router.php b/system/core/Router.php
index 7be508fef..6893e6e92 100644
--- a/system/core/Router.php
+++ b/system/core/Router.php
@@ -270,7 +270,7 @@ class CI_Router {
// If we've gotten this far it means that the URI does not correlate to a valid
// controller class. We will now see if there is an override
- if (!empty($this->routes['404_override']))
+ if ( ! empty($this->routes['404_override']))
{
$x = explode('/', $this->routes['404_override']);
diff --git a/system/libraries/Cache/drivers/Cache_apc.php b/system/libraries/Cache/drivers/Cache_apc.php
index e82e8e1f5..4b995c793 100644
--- a/system/libraries/Cache/drivers/Cache_apc.php
+++ b/system/libraries/Cache/drivers/Cache_apc.php
@@ -114,7 +114,7 @@ class Cache_apc extends CI_Driver {
return FALSE;
}
- list($value, $time, $ttl) = $stored;
+ list($data, $time, $ttl) = $stored;
return array(
'expire' => $time + $ttl,
diff --git a/system/libraries/Cache/drivers/Cache_memcached.php b/system/libraries/Cache/drivers/Cache_memcached.php
index a7efdc5de..5f5a31591 100644
--- a/system/libraries/Cache/drivers/Cache_memcached.php
+++ b/system/libraries/Cache/drivers/Cache_memcached.php
@@ -122,7 +122,7 @@ class Cache_memcached extends CI_Driver {
return FALSE;
}
- list($value, $time, $ttl) = $stored;
+ list($data, $time, $ttl) = $stored;
return array(
'expire' => $time + $ttl,
diff --git a/user_guide/database/utilities.html b/user_guide/database/utilities.html
index d4296fe2e..ac3841641 100644
--- a/user_guide/database/utilities.html
+++ b/user_guide/database/utilities.html
@@ -102,13 +102,13 @@ foreach($dbs as $db)<br />
}</code>
-<h2><a name="exists"></a>$this->db->database_exists();</h2>
+<h2><a name="exists"></a>$this->dbutil->database_exists();</h2>
<p>Sometimes it's helpful to know whether a particular database exists.
Returns a boolean TRUE/FALSE. Usage example:</p>
<code>
-if ($this->db->database_exists('database_name'))<br />
+if ($this->dbutil->database_exists('database_name'))<br />
{<br />
&nbsp;&nbsp; // some code...<br />
}
diff --git a/user_guide/libraries/javascript.html b/user_guide/libraries/javascript.html
index 55ad18907..18b7181b0 100644
--- a/user_guide/libraries/javascript.html
+++ b/user_guide/libraries/javascript.html
@@ -2,7 +2,7 @@
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
-<title>CodeIgniter User Guide : JavaScript Class</title>
+<title>JavaScript Driver : CodeIgniter User Guide</title>
<style type='text/css' media='all'>@import url('../userguide.css');</style>
<link rel='stylesheet' type='text/css' media='all' href='../userguide.css' />
@@ -42,7 +42,8 @@
<td id="breadcrumb">
<a href="http://codeigniter.com/">CodeIgniter Home</a> &nbsp;&#8250;&nbsp;
<a href="../index.html">User Guide Home</a> &nbsp;&#8250;&nbsp;
-Input Class
+<a href="../general/drivers.html">Drivers</a> &nbsp;&#8250;&nbsp;
+JavaScript Driver
</td>
<td id="searchbox"><form method="get" action="http://www.google.com/search"><input type="hidden" name="as_sitesearch" id="as_sitesearch" value="codeigniter.com/user_guide/" />Search User Guide&nbsp; <input type="text" class="input" style="width:200px;" name="q" id="q" size="31" maxlength="255" value="" />&nbsp;<input type="submit" class="submit" name="sa" value="Go" /></form></td>
</tr>
@@ -57,7 +58,7 @@ Input Class
<p class="important"><strong>Note:</strong> This driver is experimental. Its feature set and implementation may change in future releases.</p><br>
-<h1>Javascript Class</h1>
+<h1>Javascript Driver</h1>
<p>CodeIgniter provides a library to help you with certain common functions that you may want to use with Javascript. Please note that CodeIgniter does not require the jQuery library to run, and that any scripting library will work equally well. The jQuery library is simply presented as a convenience if you choose to use it.</p>
<h2>Initializing the Class</h2>
<p>To initialize the Javascript class manually in your controller constructor, use the <dfn>$this-&gt;load-&gt;library</dfn> function. Currently, the only available library is jQuery, which will automatically be loaded like this:</p>
@@ -82,7 +83,7 @@ Input Class
<h3>Set the path to the librarys with config items</h3>
<p>There are some configuration items in Javascript library. These can either be set in application/config.php, within its own config/javascript.php file, or within any controller usings the set_item() function. </p>
<p>An image to be used as an &quot;ajax loader&quot;, or progress indicator. Without one, the simple text message of &quot;loading&quot; will appear when Ajax calls need to be made.</p>
-<p><code>$config['javascript_location'] = 'http://localhost/codeigniter/themes/js/jquery/');<br />
+<p><code>$config['javascript_location'] = 'http://localhost/codeigniter/themes/js/jquery/';<br />
$config['javascript_ajax_img'] = 'images/ajax-loader.gif';</code></p>
<p>If you keep your files in the same directories they were downloaded from, then you need not set this configuration items.</p>