https://github.com/phpdevcommunity/php-template-engine
A simple php templating
https://github.com/phpdevcommunity/php-template-engine
Last synced: 3 months ago
JSON representation
A simple php templating
- Host: GitHub
- URL: https://github.com/phpdevcommunity/php-template-engine
- Owner: phpdevcommunity
- License: mit
- Created: 2018-05-07T19:32:52.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2022-03-16T15:13:40.000Z (almost 4 years ago)
- Last Synced: 2025-04-05T17:37:17.535Z (10 months ago)
- Language: PHP
- Homepage:
- Size: 12.7 KB
- Stars: 7
- Watchers: 1
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# PHP template engine
A simple PHP template engine
Easy to use:
``` php
$template = new Template('var/www/html/project/template', []);
echo $template->render('home-page.php');
```
With parameters:
``` php
$template = new Template('var/www/html/project/template', ['lang' => 'fr']);
echo $template->render('home-page.php', ['title' => 'Home Page']);
```
``` html
...
...
```