Change Product Container Width

  • Posts: 964
  • Thank you received: 11
  • Hikashop Business
11 years 11 months ago #79320

When there are 2 items in a row on the page, I noticed, via Firebug, that in the element.style the width is 49%. When there are 3 items the element.style width is 32%.

I am working with a very tight space and would like to change the width to 33% when there are 3 items in a row.

Where do I change that please?

Thanks in advance!!

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

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

Hi,

Which Joomla version are you using ?

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: 964
  • Thank you received: 11
  • Hikashop Business
11 years 11 months ago #79365

Joomla 2.5.8

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

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

Hi,

Edit the view "product / listing_div" and add something like:

if((int)$width == 32)$width = 33;
Before:
?>
			<div class="hikashop_product hikashop_product_column_<?php echo $current_column; ?> hikashop_product_row_<?php echo $current_row; ?>" style="width:<?php echo $width;?>%;">

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

  • Posts: 964
  • Thank you received: 11
  • Hikashop Business
11 years 11 months ago #79473

Thank you. Appreciate it!!!

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

  • Posts: 88
  • Thank you received: 19
8 years 4 weeks ago #253847

I know this is an old thread, but found as I was searching the same question.
I don't see the reason to use 32% width in a 3 column setup - just seems odd.

I would modify line 84 in product -> listing_div

Change:

$width = (double)(100/$columns);

To:

$width = (double)(100/$columns);

That makes the with of the product containers match the container much better. Results in a style width = 33.333333333333%;

The following user(s) said Thank You: Mohamed Thelji

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

Time to create page: 0.084 seconds
Powered by Kunena Forum