Yii Framework Sphinx full text search engine extension
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.github
docs
src
tests
.editorconfig
.gitattributes
.gitignore
.travis.yml
CHANGELOG.md
LICENSE.md
README.md
UPGRADE.md
composer.json
phpunit.xml.dist

README.md

Yii Framework Sphinx full text search engine extension


This extension adds Sphinx full text search engine extension for the Yii framework. It supports all Sphinx features including Real-time Indexes.

For license information check the LICENSE-file.

Documentation is at docs/guide/README.md.

Latest Stable Version Total Downloads Build Status

Requirements

At least Sphinx version 2.0 is required. However, in order to use all extension features, Sphinx version 2.2.3 or higher is required.

Installation

The preferred way to install this extension is through composer.

composer require --prefer-dist yiisoft/yii-sphinx

Configuration

This extension interacts with Sphinx search daemon using MySQL protocol and SphinxQL query language. In order to setup Sphinx "searchd" to support MySQL protocol following configuration should be added:

searchd
{
    listen = localhost:9306:mysql41
    ...
}

To use this extension, simply add the following code in your application configuration:

return [
    //....
    'components' => [
        'sphinx' => [
            'class' => yii\sphinx\Connection::class,
            'dsn' => 'mysql:host=127.0.0.1;port=9306;',
            'username' => '',
            'password' => '',
        ],
    ],
];