...取返回结果是这样的, a:2:{s:6:"status";s:2:"ok";s:5:"words";a:1:{i:0;a:5:{s:4:"word";s:12:"在线测试";s:3:"off";i:0;s:3:"len";i:12;s:3:"idf";d:8.19999980926513671875;s:4:"attr";s:1:"n";}}} 我如何用php从中提取出分词结果,谢谢
...。 目前换了个版本,在Deepin下,(基于Ubuntu的),下载1.3.0和1.2.0,先后放到/opt下,解压后,都发生了一样的问题: [code]abc-VirtualBox xunsearch # cat setup.log checking for a BSD-compatible install... /usr/bin/install -c checking whether build environm...
[quote='backluck' pid='3650' dateline='1280380226'] [quote]int scws_has_word(scws_t s, char *xattr) { int off, cnt, xmode = SCWS_NA; scws_res_t res, cur; char *word; word_attr *at = NULL; if (!s || !s->txt) return 0; __PARSE_XATTR__; // save th...
RCS file: /home/cvsroot/scws/libscws/scws.c,v retrieving revision 1.18 retrieving revision 1.19 diff -c -r1.18 -r1.19 *** libscws/scws.c 22 Oct 2010 11:09:46 -0000 1.18 --- libscws/scws.c 17 Jan 2011 07:29:38 -0000 1.19 *************** *** 328,333 **** --- 328,340 ---- { if (!S...
...) { var_dump($tmp); } $so->close(); 在words.txt只定义如下内容 GM 1.0 1.0 * hello指导员 1.0 1.0 * 而输出结果为: array(1) { [0]=> array(5) { ["word"]=> string(7) "GMhello" ["off"]=> int(0) ["len"]=> int(7) ["idf"]=> float(4.86477518082) ["a...
没有 #define ZTS 1 我加上 试试
我也需要这样的问题,我的是FreeBSD8.0 test.c都通不过,提示找不到scws.h 不知改如何解决啊。
试试在 phpext 目录的 configure 运行前 export CFLAGS="-O2 -DZTS=1"
..._meta:private] => Array ( [docid] => 111587 [rank] => 1 [ccount] => 0 [percent] => 75 [weight] => 2.3821949958801 ) ) [1] => XSDocument Object ...