1. Go to this page and download the library: Download monsieurbiz/mbiz_imagecrop library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
monsieurbiz / mbiz_imagecrop example snippets
$width = 100; // onal argument
$imagePath = 'foo/bar.png'; // Your image is in the /media directory. In /media/foo/ precisely.
// The method of the helper
// crop($imageRelativePath, $width, $height = null);
$imageUrl = Mage::helper('mbiz_imagecrop')->crop($imagePath, $width, $height);
$width = 100; // onal argument
$imagePath = 'foo/bar.png'; // Your image is in the /media directory. In /media/foo/ precisely.
// The method of the helper
// resize($imageRelativePath, $width, $height = null);
$imageUrl = Mage::helper('mbiz_imagecrop')->resize($imagePath, $width, $height);