split out header and footer