Implemented auto caching and clearing for image manager

- Images automatically expire after 24 hours. You can overwrite this and set the cache time (in seconds) manually.