PHP code example of ghopper / nested_set
1. Go to this page and download the library: Download ghopper/nested_set 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/ */
ghopper / nested_set example snippets
...
$pdo = new \PDO(DB_CONN_STRING, DB_USER, DB_PASS,
array(PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION)
);
print_r($ns->getTree($nd1), TRUE);