PHP code example of wenstudioasia / zinc-php
1. Go to this page and download the library: Download wenstudioasia/zinc-php 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/ */
wenstudioasia / zinc-php example snippets
use Wenstudio\ZincPhp\Zinc;
// client
$client = new Zinc('http://localhost:4080', 'admin', '123456');
$client->index_create('member');
$client->doc_create('member',['name'=>'Joe', 'age'=>20, 'role'=>'solider']);
$client->doc_create_with_id('address', 201, ['location'=>'somewhere']);
$client->search('test', 'Joe');
shell
composer