8
ok i think got it..add featured image for random article
in items_random_item.php
$mainImage = $itemsObj->getMainImage();
// check to see if GD function exist
if (!function_exists('imagecreatetruecolor')) {
$block['item_image'] = $mainImage['image_path'];
} else {
$block['item_image'] = PUBLISHER_URL . '/thumb.php?src=' . $mainImage['image_path'] . '&w=' . $imgwidth; // No $imgheight for autoheight option
}
template publisher_items_random_item.html
<img src="<{$block.item_image}>" alt="" width="100" height="100" align="left" style="padding:5px;"/>
at first i got blank page because of this warning
//CAREFUL!! with many items this will exhaust memory
remove $block['lang_fullitem'] = _MB_PUBLISHER_FULLITEM;
notw its ok
now still finding how to show 4 random instead of 1
Quote:
The only thing I can think of is to copy the random article block code and use it to create 3 custom blocks as your random items
another better way ?