Gulp and Nunjucks 06 - Combining Nunjucks and PHP

Опубликовано: 30 Март 2026
на канале: Michael Breitung
655
11

In this video we explore ways to combine Nunjucks with PHP. At first glance this looks like a strange pairing. But if you have a homepage that uses both HTML and PHP pages it makes sense. You can use Nunjucks to create the structure of your homepage using templates, partials and variables, which PHP would be used for those parts that require dynamic data - e.g. from a data base.

I show you how I restructure my gallery pages, which make use of PHP to load the page and image information dynamically, to use Nunjucks.

★☆★ Links ★☆★

Nunjucks: https://mozilla.github.io/nunjucks/

★☆★ my Github ★☆★

https://github.com/MichaelBreitung/

★☆★ homepage★☆★

http://www.michael-breitung.com

#Gulp #Nunjucks #PHP