fixed issue if id or class is not given to thumbnail