https://github.com/euskadi31/search-php
Wrapper for search engine.
https://github.com/euskadi31/search-php
Last synced: 2 months ago
JSON representation
Wrapper for search engine.
- Host: GitHub
- URL: https://github.com/euskadi31/search-php
- Owner: euskadi31
- License: mit
- Created: 2014-08-12T15:48:02.000Z (almost 11 years ago)
- Default Branch: master
- Last Pushed: 2015-03-30T11:26:48.000Z (about 10 years ago)
- Last Synced: 2025-04-09T20:05:47.259Z (2 months ago)
- Language: PHP
- Size: 289 KB
- Stars: 3
- Watchers: 2
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
README
Search Engine for PHP [](http://travis-ci.org/euskadi31/search-php)
=====================Wrapper for search engine.
Engine supported
----------------* Sphinx
* SphinxQLExample
-------~~~php
require 'path/to/vendor/autoload.php';$search = new Search\Engine\SphinxQL("127.0.0.1", 9306);
// index document
$search->insert("tweets", [
"id" => 4951957226,
"text" => "For a bit of light weekend reading how about https://github.com/php/php-langspec/blob/master/spec/php-spec-draft.md … ? Still very much work in progress, but let us know if you spot typos",
"timestamp" => 1407857815
]);$search->insert("contacts", [
"id" => 1234,
"firstname" => "Kiefer",
"lastname" => "Sutherland",
"email" => "[email protected]"
"timestamp" => 1407857945
]);$search->insert("contacts", [
"id" => 1235,
"firstname" => "Chloe",
"lastname" => "O'Brian",
"email" => "[email protected]"
"timestamp" => 1407857948
]);// search
$response = $search->search("chloe", "contacts");
~~~License
-------search-php is licensed under [the MIT license](LICENSE.md).