added caching of pages