added thumbnail support for images