1. Go to this page and download the library: Download jameslevi/silhouette 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/ */
namespace App\Config;
use Graphite\Component\Silhouette\Facade;
class DB extends Facade
{
public function __construct()
{
parent::__construct('config/db.php');
}
}
DB::enable() // Returns the value of enable property.
DB::maxRows() // Returns the value 10000.
DB::enable(false) // Change the value of "enable" to false.
DB::context()->add('min_rows', 100); // This will add new configuration property.
DB::context()->set('min_rows', 110); // This will set the value of "min_rows".
DB::context()->remove('min-rows'); // This will remove "min_rows" from the data object.
// Create a new database configuration object.
$config = new Config(__DIR__ . '/config/db.php', true);
// You cannot add new data to your muted configuration.
$config->add('driver', 'mysql');
namespace App\Config;
use Graphite\Component\Silhouette\Facade;
class DB extends Facade
{
public function __construct()
{
parent::__construct('config/db.php', true);
}
}
Loading please wait ...
Before you can download the PHP files, the dependencies should be resolved. This can take some minutes. Please be patient.