summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--system/codeigniter/Common.php15
-rw-r--r--system/helpers/text_helper.php2
-rw-r--r--system/libraries/Exceptions.php2
-rw-r--r--system/libraries/Input.php2
4 files changed, 13 insertions, 8 deletions
diff --git a/system/codeigniter/Common.php b/system/codeigniter/Common.php
index a4531a7d0..885cca2f5 100644
--- a/system/codeigniter/Common.php
+++ b/system/codeigniter/Common.php
@@ -79,10 +79,15 @@ function &_load_class($class, $instantiate = TRUE)
*/
function &_get_config()
{
- static $conf;
-
- if ( ! isset($conf))
+ static $main_conf;
+
+ if ( ! isset($main_conf))
{
+ if ( ! file_exists(APPPATH.'config/config'.EXT))
+ {
+ show_error('The configuration file config'.EXT.' does not exist.');
+ }
+
require(APPPATH.'config/config'.EXT);
if ( ! isset($config) OR ! is_array($config))
@@ -90,9 +95,9 @@ function &_get_config()
show_error('Your config file does not appear to be formatted correctly.');
}
- $conf[0] =& $config;
+ $main_conf[0] =& $config;
}
- return $conf[0];
+ return $main_conf[0];
}
diff --git a/system/helpers/text_helper.php b/system/helpers/text_helper.php
index e4f816eb1..e2da32746 100644
--- a/system/helpers/text_helper.php
+++ b/system/helpers/text_helper.php
@@ -266,7 +266,7 @@ function highlight_code($str)
// or B) whether the PHP tags enclose the entire string, we will add our
// own PHP tags around the string along with some markers to make replacement easier later
- $str = '<?php //tempstart'."\n".$str.'//tempend ?>'; // <?
+ $str = '<?php //tempstart'."\n".$str.'//tempend ?>';
// All the magic happens here, baby!
$str = highlight_string($str, TRUE);
diff --git a/system/libraries/Exceptions.php b/system/libraries/Exceptions.php
index a72dbf841..c3af801ae 100644
--- a/system/libraries/Exceptions.php
+++ b/system/libraries/Exceptions.php
@@ -53,7 +53,7 @@ class CI_Exceptions {
*/
function CI_Exceptions()
{
- log_message('debug', "Output Class Initialized");
+ // Note: Do not log messages from this constructor.
}
// END CI_Exceptions()
diff --git a/system/libraries/Input.php b/system/libraries/Input.php
index 6aba5dd43..dbf939b18 100644
--- a/system/libraries/Input.php
+++ b/system/libraries/Input.php
@@ -430,7 +430,7 @@ class CI_Input {
* But it doesn't seem to pose a problem.
*
*/
- $str = str_replace(array('<?php', '<?PHP', '<?', '?>'), array('&lt;?php', '&lt;?PHP', '&lt;?', '?&gt;'), $str); // <?php BBEdit bug fix
+ $str = str_replace(array('<?php', '<?PHP', '<?', '?>'), array('&lt;?php', '&lt;?PHP', '&lt;?', '?&gt;'), $str);
/*
* Compact any exploded words