windsurfer Posted April 21, 2020 Share Posted April 21, 2020 I would like the product image size to be smaller but i have not been able to find where to change that. And i have search all the files for the settings. Any suggestions would be nice. Link to comment Share on other sites More sharing options...
bsmither Posted April 21, 2020 Share Posted April 21, 2020 CubeCart requires that the skin determine the appropriate size to fit the real estate given to the image for each of several named sizes. You can find the named sizes in the skin's config.xml file, along with the maximum size of the derived image's longest side, and the JPG/PNG compression quality. Link to comment Share on other sites More sharing options...
windsurfer Posted April 21, 2020 Author Share Posted April 21, 2020 So which one is what ? As you can see in my previous post the the max width is 500 and height is 500 When i change the <image reference="medium" maximum="500" quality="80" default="noimage.png" /> to say 300 nothing happens and that is the only one that says 500 To me it almost looks like it is hard coded somewhere but i can't find it. Also below there is no reference for product which i assume would be for the image on the product page. Link to comment Share on other sites More sharing options...
bsmither Posted April 22, 2020 Share Posted April 22, 2020 CubeCart caches the info found in the config.xml file. Please have CubeCart clear its internal cache. However, let's look at /classes/catalogue.class.php, public function displayCategory(). About 14 lines into the function we find that the image assigned to this catagory is going to be rendered as the named deriviative 'category'. That means CubeCart will derive an image that is 800 pixels on its longest size and cache it in /images/cache/. The skin template code will take {$category.image} and use it in a <img> tag. Note: the nature of the Foundation skin is that in almost all places, an image will get scaled to fit a smaller area of page real estate - if the CSS allows it. (I disagree with this approach. This creates a dependent connection between controller code and the viewer code. I would pass the name of the image and let the skin code add whatever is necessary to distinguish the complete filenames based on variations in size or whatever. Better still, have just one of each image and let the browser scale it to the required size. This would inhibit some innovative solutions to having small sized images be different than the larger counterparts - something I did frequently with CC3.) This is slightly different than displaying the images on the View Product page. In element.product_horizontal_gallery.php. we see that several sizes of image are being used. In this case, Catalogue->productAssign() creates an array of all derived image filenames as listed in the skin's config.xml. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.