added post loop around image loop