PHPackages                             voycey/cakephp-sphinxsearch - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. voycey/cakephp-sphinxsearch

ActiveCakephp-plugin

voycey/cakephp-sphinxsearch
===========================

Sphinxsearch plugin for CakePHP 3.x

0.1.5(10y ago)31143[1 issues](https://github.com/voycey/cakephp-sphinxsearch/issues)MITPHPPHP &gt;=5.4.16

Since Nov 17Pushed 9y agoCompare

[ Source](https://github.com/voycey/cakephp-sphinxsearch)[ Packagist](https://packagist.org/packages/voycey/cakephp-sphinxsearch)[ Docs](https://github.com/voycey/sphinxsearch-cakephp3)[ RSS](/packages/voycey-cakephp-sphinxsearch/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependencies (3)Versions (6)Used By (0)

Sphinx plugin for CakePHP
=========================

[](#sphinx-plugin-for-cakephp)

[![Latest Stable Version](https://camo.githubusercontent.com/f43accb221e06d6732fd3971d060bbe8bd15c54eebf7f08ed376effcc316f545/68747470733a2f2f706f7365722e707567782e6f72672f766f796365792f63616b657068702d737068696e787365617263682f762f737461626c65)](https://packagist.org/packages/voycey/cakephp-sphinxsearch) [![Total Downloads](https://camo.githubusercontent.com/d2af69526404096aaa9991386719fd9969d580e4ac3cfeda96f996243154ba42/68747470733a2f2f706f7365722e707567782e6f72672f766f796365792f63616b657068702d737068696e787365617263682f646f776e6c6f616473)](https://packagist.org/packages/voycey/cakephp-sphinxsearch) [![Latest Unstable Version](https://camo.githubusercontent.com/f73bddacb91cae8f4e44f9a799a8f06d5dd1e687bf71049a952ca2ff1e514761/68747470733a2f2f706f7365722e707567782e6f72672f766f796365792f63616b657068702d737068696e787365617263682f762f756e737461626c65)](https://packagist.org/packages/voycey/cakephp-sphinxsearch) [![License](https://camo.githubusercontent.com/f93ec36e41dc985059eb6345a5e2876c9b6115ef13d2ef8a7b7993f8c7116c82/68747470733a2f2f706f7365722e707567782e6f72672f766f796365792f63616b657068702d737068696e787365617263682f6c6963656e7365)](https://packagist.org/packages/voycey/cakephp-sphinxsearch)

For earlier versions of CakePHP (2.x)
-------------------------------------

[](#for-earlier-versions-of-cakephp-2x)

Please use the 2.x branch and follow the readme instructions under that for usage instructions

Installation
------------

[](#installation)

You can install this plugin into your CakePHP application using [composer](http://getcomposer.org).

The recommended way to install composer packages is:

```
composer require voycey/cakephp-sphinxsearch

```

\##Basic Documentation

I designed this as a replacement for the binary API access for Sphinxsearch that I was using on 2.x ()

It currently has one function and that is to query the provided index and return the matching records in a CakePHP friendly format (In this case as Query objects and Entities).

\##How to use

- Install the package with composer as above
- Add `Plugin::load('Sphinx');` to your bootstrap.php
- Attach the behaviour to a table you wish to search on (There must be an index that is generated from this model - the behaviour works by pulling the ID's from Sphinx and then fetching them from the DB (See TODO's for improving this)
- Behavior config options:
    - `'connection' => ['host' => 'hostname', 'port' => 'port']` (default hostname is 'localhost' and default port is 9306)
    - `'defaultIndex' => 'index_name'`

```
