sngrl\SphinxSearch\SphinxSearch::search PHP Method

    public function search($string, $index_name = null)
    {
        $this->_search_string = $string;
        if (null !== $index_name) {
            // if index name contains , or ' ', multiple index search
            if (strpos($index_name, ' ') || strpos($index_name, ',')) {
                if (!isset($this->_config['mapping'])) {
                    $this->_config['mapping'] = false;
                }
            }
            $this->_index_name = $index_name;
        }
        $this->_connection->resetFilters();
        $this->_connection->resetGroupBy();
        return $this;
    }