Download the PHP package best-served-cold/laravel-zendsearch without Composer

On this page you can find all versions of the php package best-served-cold/laravel-zendsearch. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package laravel-zendsearch

Build Status Build Status Code Coverage Scrutinizer Code Quality Latest Stable Version SensioLabsInsight

LaravelZendSearch

A fast implementation of ZendSearch hooking into Laravel eloquent. Utilise the power of Lucene without installing a secondary service such as Elasticsearch or Solr.

After using a couple of packages for ZendSearch in Laravel I was disappointed with the performance, so I created my own.

Installation

Follow these steps to get the package in place:

Setup

Update composer and then add the ServiceProvider to config/app.php:

I'm not keen on Facades, but if you want to use one, add it to the aliases in config/app.php:

Publish

Get your config published:

Usage

Indexing

Add the and use it in the models you want to use:

Then add the method and populate it with the fields you want to be indexed:

If you want to "boost" fields, then add the following method:

The index will build automatically from there.

Relations

If you want to index relations, make sure you create your method and then add the relation to the array in your model.

Building

If you have existing data or have changed your search fields, you can rebuild the index from scratch:

Destroy:

Optimise:

I'll work on a scheduler in the near future, but make sure you optimise your index regularly. I'd suggest scheduling it yourself for now every hour or so.

Searching

Basic

Create a search instance:

Deleting

Advanced

Filters

There are two basic filters implemented in the configuration which you can override, StopWords and ShortWords. You can, however, change both the filters and the analyzer manually to preset ZendSearch classes or custom classes:

Helpers

To assist in debugging, there are a few helpers which can assist:

Features to come

This is the first stable version which I've made mainly for my own use on another project. I will add the following in due course though.


All versions of laravel-zendsearch with dependencies

PHP Build Version
Package Version
Requires php Version >=5.6.4
zendframework/zendsearch Version ^2.0@RC
illuminate/support Version ^5.3
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package best-served-cold/laravel-zendsearch contains the following files

Loading the files please wait ....