PHP115
From mi-linux
Jump to navigationJump to searchMain Page >> Web Application Development >> Workbook >> Template Engines
Please note that this is an advanced topic. Make sure that you have worked through all the previous sections of this workbook before proceeding.
Template engines
There are many PHP template engines out there, there are some of the most popular ones:
- Twig - probably the best current, framework-independent template engine.
- Mustache - also very popular, but very simple and so not suitable for more complex projects.
- Smarty - very old, and the website looks very dated, but the product itself is very good and still actively maintained!
- Blade - Blade comes with Laravel, a very popular PHP framework, and cannot easily be used without Laravel.
- Volt - Volt is packaged with the Phalcon PHP framework, but can be used as a standalone product.
Here is an interesting comparison of the template engines above.
In this tutorial we will look at Twig
Installing Twig
Please read the installation notes on the official website.