This is what the image should look like:


However, this is was some of the images will come out like:


I am creating a single image, emailing it, then creating another image and emailing it and so on overwriting the previous image each time. Currently I am only doing it with 15 images, but it needs to be scaled up to about 200.
Anyone have any ideas about what might be going on? Any help at all would be appreciated, im pretty new to php