summaryrefslogtreecommitdiffstats
path: root/system/database/DB_active_rec.php
diff options
context:
space:
mode:
authorPhil Sturgeon <email@philsturgeon.co.uk>2012-06-11 15:16:35 +0200
committerPhil Sturgeon <email@philsturgeon.co.uk>2012-06-11 15:16:35 +0200
commit686ff126762c0923556036a3cf73abb9390a7e67 (patch)
treec0aedf7f9ce68ed3e5880f9f1ba14ddf03eb7083 /system/database/DB_active_rec.php
parent918eaef728eaf49387083b39add7106e029fcfb4 (diff)
parentcef5bda9765080b818898811023d9ab427b0faf2 (diff)
Fixed conflicts
Why were there conflicts merging into master?
Diffstat (limited to 'system/database/DB_active_rec.php')
-rw-r--r--system/database/DB_active_rec.php12
1 files changed, 8 insertions, 4 deletions
diff --git a/system/database/DB_active_rec.php b/system/database/DB_active_rec.php
index 7bab729f5..10febb1fc 100644
--- a/system/database/DB_active_rec.php
+++ b/system/database/DB_active_rec.php
@@ -255,7 +255,7 @@ class CI_DB_active_record extends CI_DB_driver {
*/
public function from($from)
{
- foreach ((array)$from as $val)
+ foreach ((array) $from as $val)
{
if (strpos($val, ',') !== FALSE)
{
@@ -660,8 +660,12 @@ class CI_DB_active_record extends CI_DB_driver {
$prefix = (count($this->ar_like) == 0) ? '' : $type;
$v = $this->escape_like_str($v);
-
- if ($side == 'before')
+
+ if ($side == 'none')
+ {
+ $like_statement = $prefix." $k $not LIKE '{$v}'";
+ }
+ elseif ($side == 'before')
{
$like_statement = $prefix." $k $not LIKE '%{$v}'";
}
@@ -1643,7 +1647,7 @@ class CI_DB_active_record extends CI_DB_driver {
if (strpos($table, " ") !== FALSE)
{
// if the alias is written with the AS keyword, remove it
- $table = preg_replace('/ AS /i', ' ', $table);
+ $table = preg_replace('/\s+AS\s+/i', ' ', $table);
// Grab the alias
$table = trim(strrchr($table, " "));