public function testGeoAnchor() { $sphinx = new SphinxClient(); $sphinx->setGeoAnchor('lat', 'long', 0.4, 0.4)->setMatchMode(SphinxClient::SPH_MATCH_EXTENDED)->setSortMode(SphinxClient::SPH_SORT_EXTENDED, '@geodist desc')->setFilterFloatRange('@geodist', 0, 1934127); $results = $sphinx->query('a'); $this->assertEquals(array_keys($results['matches']), array('1', '3', '4')); }
/** * {@inheritdoc} */ public function setGeoAnchor($attrlat, $attrlong, $lat, $long) { return $this->proxy->setGeoAnchor($attrlat, $attrlong, $lat, $long); }