PHP code example of hnhdigital-os / laravel-model-search
1. Go to this page and download the library: Download hnhdigital-os/laravel-model-search 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/ */
hnhdigital-os / laravel-model-search example snippets
use HnhDigital\ModelSearch\ModelTrait as ModelSearchTrait;
class SomeModel extends Model
{
use ModelSearchTrait;
}
SomeModel::search(['title' => 'Test']);
SomeModel::search(['title' => [['=', 'Test']]]);
SomeModel::search(['title' => '= Test']);
SomeModel::search(['title' => '!= Test']);