Custom Page Templates: Page Header and Footer
Merchants define the contents of the page header and footer in one location in the back office so that it can be applied easily to all pages. However, merchants can choose whether the header and footer are displayed on any given page, so your template should check for this condition.
- Merchants can put HTML tags in most ShopSite fields, and your template should be able to handle that. For example, it's quite likely that the merchant would put some HTML in the page header. If your template also puts HTML tags around the header, your tags may cause conflicts with the merchant's HTML. Of course, if you are the merchant or you're building a template for just one store, you should be able to make your fields and template work together. The data used to create the Resulting Page has HTML in both the header and footer.
- You may want to include the [-- PrevNext --] tag before the footer or somewhere on the page. If a merchant enables automatic pagination (maximum number of products per page), this tag will output the links to navigate between the generated pages. If the merchant does not enable pagination, or if there are less than the maximum number of products assigned to that page, the tag will output nothing. Any surrounding HTML used to format the pagination links will still be in the resulting page, so you may want to use an IF tag to test whether the merchant has enabled pagination.
Header and Footer Example Page Template Resulting Page