1. Go to this page and download the library: Download glenjamin/dimple 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/ */
glenjamin / dimple example snippets
$di = new \Dimple\Dimple();
$di->setup('app', function($di) {
return new Application($di->get('db'), $di->get('logger'));
});
$di->setup('db', function($di) {
return new \PDO($di->get('db-string'));
});
$di->set('dbstring', 'mysql://localhost');
$di->setup('logger', function($di) {
return new Logger($di->get('logfile', '/dev/null'));
});
$app = $di->get('app');
$app->run();