PHP code example of chp / textcontent
1. Go to this page and download the library: Download chp/textcontent 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/ */
chp / textcontent example snippets
$di->set('ContentController', function() use ($di) {
$controller = new \Chp\TextContent\ContentController();
$controller->setDI($di);
return $controller;
});
$di->set('BlogController', function() use ($di) {
$controller = new \Chp\TextContent\BlogController();
$controller->setDI($di);
return $controller;
});
$di->set('PageController', function() use ($di) {
$controller = new \Chp\TextContent\PageController();
$controller->setDI($di);
return $controller;
});