Jonathan Drake
2009-Feb-04 19:17 UTC
[Xapian-discuss] Odd issue with PHP Bindings and TermIterator
I'm using the Enquirer to return a term iterator for each document in the MSet. Rather oddly since normally you use a deference to access the string from the iterator, in the PHP bindings the function is called get_term(). So I call a simple $term_it->get_term() and it returns a string but the string returned always starts with a capital 'Z' For instance: string(11) "Zhern?ndez" string(7) "ZSoccer" Ignore the fact that the first string reports 11 character entries (PHP uses ASCII mode and the accented character uses 2 entries to be displayed properly). I'm wondering if this is expected behavior? Is this the way its stored in the Xapian database or do we have an off by one error somewhere in the bindings? Any input would be great Thanks, Jonathan
James Aylett
2009-Feb-04 19:25 UTC
[Xapian-discuss] Odd issue with PHP Bindings and TermIterator
On Wed, Feb 04, 2009 at 11:17:29AM -0800, Jonathan Drake wrote:> I'm using the Enquirer to return a term iterator for each document in > the MSet. Rather oddly since normally you use a deference to access > the string from the iterator, in the PHP bindings the function is > called get_term(). So I call a simple $term_it->get_term() and it > returns a string but the string returned always starts with a capital > 'Z'.This is correct; check out <http://xapian.org/docs/termgenerator.html#stemming> for more details. J -- James Aylett talktorex.co.uk - xapian.org - uncertaintydivision.org