Cleanup the layout on multiple pages