added thumbnail code