- Moving them inside the proper "if" conditions.
- Adding a new setting to the print_header() function (call it "emptybody"), to make that the header directly avoid writing any content in the body (but the mandatory "page" and "content" divs, of course).
Ciao