Better image finding & fixed spacing

Previously, the script iterated through various directories to find the
image. Now, we just check whether the image is in the uploads folder,
or whether it's in one of the theme's folders.. in any case, the image
being resized should only be in those folders anyway.