Adding 'logged in' check and templates for header/footer