I got it working, for what it was suppose to do, but I need help modifying it cause I need it on products.tpl and I need it to pull the thumbnail not the large image. Tried just copying the code from product to products but that didn't work and all the images came up as Missing.
-Eric