翻代码发现这个...存档而已。
//使用代码
$where[] = array('array',$where);
//源文件解释
foreach($where as $k => $w) {
$eq=strtoupper($w[0]);
…………
if($eq=='ARRAY'){
$c='';
$sql_array='';
if(!is_array($w[1]))continue;
if(count($w[1])==0)continue;
foreach ($w[1] as $x=>$y) {
$y[1]=$this->db->EscapeString($y[1]);
$sql_array .= $c . " $y[0]='$y[1]' ";
$c='OR';
}
$sqlw .= $comma . '(' . $sql_array . ') ';
}转载请注明:鸟儿博客 » ZBLOGPHP版本获取文章列表实现或(OR)查询