how to make a placeholder for missing images in opencart (noimage)
in the file catalogcontrollerproductcategory.php
in the index action
instead of
$image =false;
foreach ($results as $result) {
if ($result['image']) {
$image = $this->model_tool_image->resize($result['image'], $this->config->get('config_image_product_width'), $this->config->get('config_image_product_height'));
} else {
$image = $this->model_tool_image->resize('no_image.jpg', $this->config->get('config_image_product_width'), $this->config->get('config_image_product_height'));
//$image =false;
}
Comments