A common requirement for a website is to display a navigation menu as part of the header. In the scenario where each page defines its own header and footer, it is straightforward to highlight a menu option to indicate the page that is currently being displayed. When a template provides the header and footer information, a mechanism is required to allow the page to identify itself to the template, which can then highlight the appropriate menu option.
In this recipe, we will create a Visualforce template that provides header and footer content to four other Visualforce pages: a Home page, an About page, a Contact page, and a Links page. We will then make these pages available publicly available via an unauthenticated Force.com site.
This recipe requires that you have already completed the Creating a site recipe, as it relies on the custom domain and Force.com site created in that recipe.