How to save layouts and header and footer layouts