4 ms·
Sensible includes/templating with PHP or whatever stack you're building on. This is so useful when done well, but I don't know how many times I've seen otherwis
by komlenic 16y ago
Sensible includes/templating with PHP or whatever stack you're building on. This is so useful when done well, but I don't know how many times I've seen otherwise intelligent people sitting there copying the same markup/code into every file or banging their head off the wall when Dreamweaver or some other bloated suite tries to update a "template" on 4500 files and upload them to production.
The idea is simple: anything that you're going to put in more than a couple places/files, should be pulled out and put in a separate included file. Your doctype declaration? Your nav bar? Your generic site-wide footer? Put all these kinds of things in includes, update 1 file later and your changes take place everywhere.