[Xapian-discuss] PHP error in index_text()

James Aylett james-xapian at tartarus.org
Mon Sep 1 11:55:04 BST 2008


On Sun, Aug 31, 2008 at 07:37:24PM -0500, Yannick Warnier wrote:

> Fatal error: No matching function for overloaded
> 'TermGenerator_index_text' in /usr/share/php/xapian.php on line 1498
> 
>                 case 1: case 2: TermGenerator_index_text($this->_cPtr,
> $text,$weight); break;
> 
> The call to that function (index_text()) in my PHP script is actually
> made (in this case) with 2 parameters from my PHP script:
> - one empty string
> - 1

Is it definitely 1 and not "1"? That would trigger this, because the
bindings (I believe) are fairly type strict here. (In general they
have to be in order to get overloaded function calls to work sanely.)

Try also just dropping the $weight parameter, to ensure that $text is
really a string, and not something that tests == in PHP to "" such as
NULL, 0 etc..

J

-- 
/--------------------------------------------------------------------------\
  James Aylett                                                  xapian.org
  james at tartarus.org                               uncertaintydivision.org



More information about the Xapian-discuss mailing list