get thumbnail functionality