diff options
author | admin <devnull@localhost> | 2006-08-27 17:28:31 +0200 |
---|---|---|
committer | admin <devnull@localhost> | 2006-08-27 17:28:31 +0200 |
commit | 57b3d39cb79bb3b8d193e0e345a62e3396e519f2 (patch) | |
tree | a453970cc05172c819df5bd7a04b3c431e67a37a /system/drivers | |
parent | 141808ad31d4eefad4c6c3dbaf8306fac2342668 (diff) |
Diffstat (limited to 'system/drivers')
-rw-r--r-- | system/drivers/DB_active_record.php | 2 | ||||
-rw-r--r-- | system/drivers/DB_driver.php | 10 |
2 files changed, 6 insertions, 6 deletions
diff --git a/system/drivers/DB_active_record.php b/system/drivers/DB_active_record.php index 373c0f626..f1995c807 100644 --- a/system/drivers/DB_active_record.php +++ b/system/drivers/DB_active_record.php @@ -663,7 +663,7 @@ class CI_DB_active_record extends CI_DB_driver { if (count($this->ar_where) == 0) { - if ($this->debug) + if ($this->db_debug) { return $this->display_error('db_del_must_use_where'); } diff --git a/system/drivers/DB_driver.php b/system/drivers/DB_driver.php index ed18d54e5..3a2a5e9bc 100644 --- a/system/drivers/DB_driver.php +++ b/system/drivers/DB_driver.php @@ -86,7 +86,7 @@ class CI_DB_driver { { log_message('error', 'Invalid DB Connection String'); - if ($this->debug) + if ($this->db_debug) { return $this->display_error('db_invalid_connection_str'); } @@ -265,7 +265,7 @@ class CI_DB_driver { if ( ! function_exists($function)) { - if ($this->debug) + if ($this->db_debug) { return $this->display_error('db_unsupported_function'); } @@ -425,7 +425,7 @@ class CI_DB_driver { { if ($table == '') { - if ($this->debug) + if ($this->db_debug) { return $this->display_error('db_field_param_missing'); } @@ -472,7 +472,7 @@ class CI_DB_driver { { if ($table == '') { - if ($this->debug) + if ($this->db_debug) { return $this->display_error('db_field_param_missing'); } @@ -535,7 +535,7 @@ class CI_DB_driver { // Just in case the replacement string contains the bind // character we'll temporarily replace it with a marker $val = str_replace($this->bind_marker, '{%bind_marker%}', $val); - $sql = preg_replace("#".preg_quote($this->bind_marker)."#", $val, $sql, 1); + $sql = preg_replace("#".preg_quote($this->bind_marker, '#')."#", str_replace('$', '\$', $val), $sql, 1); } return str_replace('{%bind_marker%}', $this->bind_marker, $sql); |