PHP code example of mobilexco / laravel-scout-elastic
1. Go to this page and download the library: Download mobilexco/laravel-scout-elastic library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
mobilexco / laravel-scout-elastic example snippets
// config/scout.php
// Set your driver to elasticsearch
'driver' => env('SCOUT_DRIVER', 'elasticsearch'),
...
'elasticsearch' => [
'index' => [
// if using more than one index, you likely want to change this to each of
// your indexes. quite possibly using searchableAs on your models.
env('ELASTICSEARCH_INDEX', 'scout')
],
'hosts' => [
env('ELASTICSEARCH_HOST', 'http://localhost'),
],
'perModelIndex' => true,
],
...
// config/laravel-scout-elastic
// set this if you don't want to ,
...
'region' => env('AWS_REGION', 'us-west-2'),
...