4 ms·
PHP isn't really used as a template language any more. Most people use a different template language for the views. I've implemented two myself[0][1] but an ear
by jbboehr 4y ago
PHP isn't really used as a template language any more. Most people use a different template language for the views. I've implemented two myself[0][1] but an early one was Smarty[2] and there are many others. I hear Twig is pretty good[3].
[0]: https://github.com/jbboehr/php-handlebars https://github.com/jbboehr/php-handlebars
[1]: https://github.com/jbboehr/php-mustache https://github.com/jbboehr/php-mustache
[2]: https://www.smarty.net/ https://www.smarty.net/
[3]: https://twig.symfony.com/ https://twig.symfony.com/
- ptx 4y agoIf you're not using it as a template language though, why use PHP in the first place? Having to use a separate framework puts it on equal footing with every other language.
- 8n4vidtmkvmk 4y agoit just works with no fuss. no compiling. no memory leaks because it dies after every request. the standard library, despite being horrifically inconsistent, has everything you need