![mjoel](https://xoops.org/uploads/avatars/cavt4db22440776e9.jpg)
here's what i did so far following from some example ... but its not working..i got 500 error page
in publisher/author_items.php...my image code is after the line rating
..i added the bold part
$categories[$catId]['count_items']++;
$categories[$catId]['count_hits'] += $item->counter();
$categories[$catId]['items'][] = [
'title' => $item->getTitle(),
'hits' => $item->counter(),
'link' => $item->getItemLink(),
'published' => $item->getDatesub(_SHORTDATESTRING),
//'rating' => $xoopsLocal->number_format((float)$item->rating())
'rating' => $item->rating(),
'image' => $item->getMainImage(),
];
$mainImage = $item->getMainImage();
// check to see if GD function exist
if (!function_exists('imagecreatetruecolor')) {
$item['image'] = $mainImage['image_path'];
} else {
$item['image'] = PUBLISHER_URL . '/thumb.php?src=' . $mainImage['image_path'] . '&w=' . $imgWidth; // No $imgHeight for autoheight option
}
}
}
in template publisher_author_items.tpl i used
$item.item_image
please help thank you