Hide image for some products

  • Posts: 21
  • Thank you received: 0
11 years 6 months ago #105289

I want some of my products to NOT require a image, i.e. hide the image

Please Log in or Create an account to join the conversation.

  • Posts: 26158
  • Thank you received: 4028
  • MODERATOR
11 years 6 months ago #105303

Hi,

The images are not required on products. But if there is no image, HikaShop will display the default image.
There are different solutions possible but we have to know more about your requirement in order to give you the most appropriate solution.

What do you want to do exactly ?
How do you want to make the difference between a product with and without an image ?

Regards,


Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.

Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.

Please Log in or Create an account to join the conversation.

  • Posts: 21
  • Thank you received: 0
11 years 6 months ago #105317

When I do not choose an image for a product, I do not want an image to display, just the product name.

Please Log in or Create an account to join the conversation.

  • Posts: 21
  • Thank you received: 0
11 years 6 months ago #105318

...and no default image

Please Log in or Create an account to join the conversation.

  • Posts: 82868
  • Thank you received: 13375
  • MODERATOR
11 years 6 months ago #105382

For the listings, you can edit the file listing_img_title of the view product via the menu display->Views and change the line:
if($this->config->get('thumbnail',1)){

to:
if($this->config->get('thumbnail',1) && !empty($this->row->file_path)){

For the product page, you can change the line:
} else {

to:
} elseif(!empty($image->file_path)) {

in the file "show_block_img" via the menu display->Views

Please Log in or Create an account to join the conversation.

Time to create page: 0.110 seconds
Powered by Kunena Forum