diff options
Diffstat (limited to 'system')
-rw-r--r-- | system/database/DB_driver.php | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/system/database/DB_driver.php b/system/database/DB_driver.php index 04490c824..bbefbe566 100644 --- a/system/database/DB_driver.php +++ b/system/database/DB_driver.php @@ -1706,7 +1706,10 @@ abstract class CI_DB_driver { // If a parenthesis is found we know that we do not need to // escape the data or add a prefix. There's probably a more graceful // way to deal with this, but I'm not thinking of it -- Rick - if (strpos($item, '(') !== FALSE) + // + // Added exception for single quotes as well, we don't want to alter + // literal strings. -- Narf + if (strpos($item, '(') !== FALSE OR strpos($item, "'") !== FALSE) { return $item; } |