You are here:  » Grid View - Massive Images....


Grid View - Massive Images....

Submitted by ChrisNBC on Tue, 2013-07-16 15:17 in

Hi David,

Hope all is going well.

I wondered if you might be able to help me resolve an issue I have with the grid view mod described in http://www.pricetapestry.com/node/3954. I have implemented the changes and also re applied all my existing mods to the code. All works fine, except when I view the grid results and the product images are displayed in giant size on the page? I've pasted an example below.

I wondered if you might be able to suggest how I could resolve this?

{link saved}

Thanks in advance.
Best Regards
Chris

Submitted by support on Tue, 2013-07-16 15:50

Hi Chris,

The version of html/searchresults.php included in the patch doesn't include a fixed dimension, so I will update this, in the mean time, if you look for the following code at line 39 of that file:

<a href='<?php print $product["productHREF"]; ?>'><img border='0' src='<?php print $product["image_url"]; ?>' alt='<?php print $product["name"]; ?>' /></a>

...and REPLACE with:

<a href='<?php print $product["productHREF"]; ?>'><img height='80' border='0' src='<?php print $product["image_url"]; ?>' alt='<?php print $product["name"]; ?>' /></a>

...that will apply a constant height of 80 (px) to the images in grid view. It's best to only fix a single dimension, otherwise images will appear distorted...

Cheers,
David.
--
PriceTapestry.com

Submitted by ChrisNBC on Tue, 2013-07-16 21:14

Hi David,

Perfect!...it's fixed. Thanks as always for the quick response.

Regards
Chris