adding script to get an image object