PHP code example of haidarvm / simple-php-template
1. Go to this page and download the library: Download haidarvm/simple-php-template 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/ */
haidarvm / simple-php-template example snippets
//include the loader
plateEngine\Environment('path/to/templates/directory');
echo $env->render('template.php');
$env = new SimpleTemplateEngine\Environment('path/to/templates', '.php');
//will render index.php
echo $env->render('index');