... [php]function checksys($str){ $syskey = array(' AND ',' OR ',' NOT ',' AND_NOT ',' XOR ',' NEAR ',' ADJ '); $str = str_replace($syskey,' ',' '.$str.' '); $ta = explode('.',trim($str).'.'); $i = 0; $str = ''; foreach($ta as $t){ if(is_string($t) && strlen($t)>1 && is_string($ta[($i+1...
...果方法1: // 不带参数,输出:Xapian::Query((神雕侠侣:(pos=1) AND_NOT 电视剧:(pos=2))) echo $search->getQuery(); // 带参数,则解析新语句,输出:Xapian::Query((杭州:(pos=1) AND 西湖:(pos=2))) echo $search->getQuery('杭州 西湖'); // 查看搜索语句解析结...