$where['ex_account'] = array('like','%'.$p.'%');
$where['ex_nickname'] = array('like','%'.$p.'%');
$where['_logic'] = 'or';
$res = $db->where($where)->select();
$where['ex_account'] = array('like','%'.$p.'%');
$where['ex_nickname'] = array('like','%'.$p.'%');
$where['_logic'] = 'or';
$res = $db->where($where)->select();
转载于:https://www.cnblogs.com/rickons/p/4580530.html