image handling added