Improved Image Resize

OpenCart Improved Image Resize
Loading...

You can avoid the white space around image with this new approach. Force to zoom and crop them by set the fourth parameter of resize function; based on image width or height.

OpenCart v2.0.0.0, v2.0.1.0 and v2.0.1.1 supported.

OC Mod Install

  • Upload ocmod.xml in xml-file on Extensions->Extension Installer
  • Click Refresh button on Extensions->Modifications
  • Tab Slider Install on Extensions->Modules
  • After installing the module, Click Edit button and after completing the module settings click save button.

How to Use

You need to add a parameter for image resizing.

For example, you must make that change in featured module.

catalog/controller/module/featured.php in file

FIND

$image = $this->model_tool_image->resize($product_info['image'], $setting['width'], $setting['height']);

REPLACE

$image = $this->model_tool_image->resize($product_info['image'], $setting['width'], $setting['height'], 'a');

=== v1.0.1.0 CHANGELOG ===

  • Added OpenCart v2.0.1.0 and v2.0.1.1 supported

=== v1.0.0.0 CHANGELOG ===

  • Initial release

Please login or register to comment
Date Added 10/12/2014 14:17:51
Date Modified 04/05/2015 16:56:03
File Size 3.49KB
Version 1.0.1
Downloads 103
General Attributes
Date Added 10/12/2014
Last Update 14/04/2015
Product Code EPMOD31
Viewed 10397
Platform OpenCart
Tags OpenCart, Improved, Image Resize, Auto Image Resize, Auto-Type Resize, Improved Resize

Seller's Other Items

  • EPMOD31
  • You can avoid the white space around image with this new approach. Force to zoom and crop them by set the fourth parameter of resize function; based on image width or height.

    OpenCart v2.0.0.0, v2.0.1.0 and v2.0.1.1 supported.