optimize image size, modify html