[XSException] ../../../../usr/local/xunse/sdk/php/lib/XS.php(1464): Unexpected respond in search {CMD:129, ARG:514} 还是该错误 已更新和设置 无法解决
setSort() 方法 public XSSearch setSort(string $field, bool $asc=false, bool $relevance_first=false) $field string 依据指定字段的值排序, 设为 null 则用默认顺序 $asc bool 是否为正序排列, 即从小到大, 从少到多, 默认为反序 $relevance_fir...
...return} array 返回搜索词组成的数组 源码: sdk/php/lib/XSSearch.class.php#L755 (显示) public function getExpandedQuery($query, $limit = 10){ $ret = array(); $limit = max(1, min(20, intval($limit))); try { $buf = XS::convert($query, 'UTF-8', $this->_charset); ...
[php][cid] index = self tokenizer = split(,) non_bool = yes[/php] 字段设置如上,解决方法如下。 [php] foreach ($keywords as $v) { $search->addQueryTerm($field, $v); }[/php]
__destruct() 方法 public void __destruct() 源码: sdk/php/lib/XS.class.php#L304 (显示) public function __destruct(){ $this->_index = null; $this->_search = null;} 析构函数 由于对象交叉引用, 如需提前销毁对象, 请强制调用该函数
...(2092): Unknown Internal Error(S#600) XS.php(1550): Unexpected respond in search {CMD:129, ARG:600} quit, IO error (ERROR:Broken pipe): XS.php(2165): Failed to recv the data from server completely (SIZE:0/8, REASON:timeout) quit, IO timeout (TIMEOUT:5): XS.php(2165): Failed to recv the ...
[code][/code] 加了。不过出现 [root@beihai365 365search]# php test.php dict content: 哦你呀 武不只 我是谁 精武英雄 1.0 1.0 tq ------- Array ( [0] => Array ( [word] => 精武英雄 [off] => 0 [len] =>...
...xs.php那段代码里。 使用自动生成的搜索骨架代码,访问search.php出现页面载入出错 。连接被重置 载入页面时到服务器的连接被重置。 // 加载 XS 入口文件 require_once '/home/who/xunsearch/sdk/php/lib/XS.php'; 这段包含代码去掉就能正常...
...327 (显示) public function getVersion(){ $cmd = new XSCommand(XS_CMD_SEARCH_SCWS_GET, XS_CMD_SCWS_GET_VERSION); $res = self::$_server->execCommand($cmd, XS_CMD_OK_INFO); return $res->buf;} 获取 scws 版本号
...t getDbTotal() {return} int 数据总量 源码: sdk/php/lib/XSSearch.class.php#L659 (显示) public function getDbTotal(){ $cmd = new XSCommand(XS_CMD_SEARCH_DB_TOTAL); $res = $this->execCommand($cmd, XS_CMD_OK_DB_TOTAL); $tmp = unpack('Itotal', $res->buf); return $tmp['tot...