random thumb

Bug

what i did for now:

is there any way I can automatically can create the array that should be randomized?

now I need to have all images named in the same way



$thumbrandlist= array("-green.jpg", "-white.jpg", "-blue.jpg", "-black.jpg", "-yellow.jpg");
//echo $thumbrandlist[rand(0,4)];
$thumbrand = "<a href='".$item_link."'><img src='http://www.domainname.com/media/bakery/thumbs/item".$item_id."/".$item['sku'].$thumbrandlist[rand(0,4)]."' border='0'/></a>";




// Replace vars with values
$vars = array('[THUMB]', '[THUMBS]', '[THUMBRAND]', '[IMAGE]', '[IMAGES]', '[TITLE]', '[PRICE]', '[DESCRIPTION]', '[CURRENCY]', '[LINK]', '[TXT_PRICE]');
$values = array($thumb, $thumbs, $thumbrand, $image, $images, stripslashes($item['title']), stripslashes($item['price']), stripslashes($item['description']), $setting_shop_currency, $item_link, $MOD_showroom['TXT_PRICE']);
echo str_replace($vars, $values, $setting_item_loop);

Bug

anyone knwo a simple way to get a random thumbnail from a product

I am making a t-shirt-shop with t-shirtdesigns available on different colors.. I would love it if the view overview would look different each pageload ...