php templating, plus footer