Override product image size

  • Posts: 182
  • Thank you received: 15
11 years 11 months ago #78941

I have a few different Product/Show_default views used differently in different categories.

In these categories I would like to set the product image size differently than in other categories.
Is there a way to override the setting in Config/Files/Images/Product page image width/height?

Could it be CSS-modified or is it code-related?

Thanks


Jan

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

  • Posts: 13201
  • Thank you received: 2322
11 years 11 months ago #78961

Hi,

I think that you can override dimensions in the view "product / listing_img_title" (or another one depending on which one you are using).
And in the Product img part, change the dimensions of the vars: "$this->image->main_thumbnail_y" & "$this->image->main_thumbnail_x".

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

  • Posts: 182
  • Thank you received: 15
11 years 11 months ago #78964

Quick question on that, how do I link that file to my own Show_xxx file?

Jan

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

  • Posts: 13201
  • Thank you received: 2322
11 years 11 months ago #79002

Hi,

I think that you can link a display type on a menu by adding a setVar in the listing view and a getVar in the "components/com_hikashop/views/product/view.html.php" file in the function "show()".
To have something like:

if(empty($productLayout))
 $productLayout = JRequest::getVar('productLayout','');
after:
$productlayout = $element->product_layout;

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

Time to create page: 0.068 seconds
Powered by Kunena Forum