PHP code example of pine3ree / pine3ree-plates-resolvers
1. Go to this page and download the library: Download pine3ree/pine3ree-plates-resolvers 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/ */
pine3ree / pine3ree-plates-resolvers example snippets
$template->render('partials::pagination', $vars);
// The search order is:
//
// 1. {/path/to/the/default/templates/directory/}partials/pagination.phtml
// 2. {/path/to/the/partials/template/folder/}pagination.phtml
$template->render('partials/pagination', $vars);
$plates = new League\Plates\Engine('/path/to/my/web/app/templates');
$plates->addFolder('news', '/path/to/my/web/app/News/templates');
$plates->addFolder('shop', '/path/to/my/web/app/Shop/templates');
// This will load the template in the global templates directory, because a
// matching template-file is found
$plates->render("news::article/read", $vars); // or simply
$plates->render("news/article/read", $vars);
// This will load the template in the module templates directory, because there
// is no matching file in the global directory
$plates->render("shop::product/index", $vars); // or simply
$plates->render("shop/product/index", $vars);
Loading please wait ...
Before you can download the PHP files, the dependencies should be resolved. This can take some minutes. Please be patient.