diff options
author | plegall <plg@piwigo.org> | 2014-09-08 09:48:55 +0000 |
---|---|---|
committer | plegall <plg@piwigo.org> | 2014-09-08 09:48:55 +0000 |
commit | 93aa6cd8325facea6faa26642b95d72c0c52456f (patch) | |
tree | b8329505fb169830b6fb621d1e169312661a5c03 /include/functions_search.inc.php | |
parent | 478249d5d040bd26bbfadee420161da103fb47a9 (diff) |
bug 3136: search by author must be an exact match, now that we have the author listbox
git-svn-id: http://piwigo.org/svn/trunk@29431 68402e56-0260-453c-a942-63ccdbb3a9ee
Diffstat (limited to '')
-rw-r--r-- | include/functions_search.inc.php | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/include/functions_search.inc.php b/include/functions_search.inc.php index 1af36d3af..28682215e 100644 --- a/include/functions_search.inc.php +++ b/include/functions_search.inc.php @@ -70,7 +70,14 @@ function get_sql_search_clause($search) $local_clauses = array(); foreach ($search['fields'][$textfield]['words'] as $word) { - $local_clauses[] = $textfield." LIKE '%".$word."%'"; + if ('author' == $textfield) + { + $local_clauses[] = $textfield."='".$word."'"; + } + else + { + $local_clauses[] = $textfield." LIKE '%".$word."%'"; + } } // adds brackets around where clauses |