remove quote, which is twiced used

This commit is contained in:
wlx 2011-12-25 02:38:50 +00:00
parent 1152e4a86d
commit 0fd88b944f
1 changed files with 2 additions and 2 deletions

View File

@ -116,7 +116,7 @@ class ServiceController extends Zend_Controller_Action
if (!empty($key)) { if (!empty($key)) {
$sql.= " and (title ilike ? or description ilike ?)"; $sql.= " and (title ilike ? or description ilike ?)";
$sql.= " order by title"; $sql.= " order by title";
$rows=$this->db->fetchAll($sql,array($e,$w,$n,$s,$this->db->quote('%'.$key.'%'),$this->db->quote('%'.$key.'%'))); $rows=$this->db->fetchAll($sql,array($e,$w,$n,$s,'%'.$key.'%','%'.$key.'%'));
} else { } else {
$sql.= " order by title limit 10"; $sql.= " order by title limit 10";
$rows=$this->db->fetchAll($sql,array($e,$w,$n,$s)); $rows=$this->db->fetchAll($sql,array($e,$w,$n,$s));