PHP code example of nyankod / jsonfiledb
1. Go to this page and download the library: Download nyankod/jsonfiledb 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/ */
nyankod / jsonfiledb example snippets
`
$db = new \nyankod\JsonDB('./data/');
$db->setTable('test');
$result = $db->select('Age', 43);
var_dump($result);
array(2) {
[0]=> array(3) { ["ID"]=> int(0) ["Name"]=> string(13) "Josef Brunzer" ["Age"]=> int(43) }
[1]=> array(3) { ["ID"]=> int(3) ["Name"]=> string(15) "Gerald Ofnsacka" ["Age"]=> int(43) }
}