templating is done for all pages