Download the PHP package dakzilla/intervention-image-helper without Composer

On this page you can find all versions of the php package dakzilla/intervention-image-helper. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package intervention-image-helper

Intervention Image helper for Magento 2

A useful template helper for applying transformations to images in Magento 2 using the Intervention Image library.

Installation

composer require dakzilla/intervention-image-helper

php bin/magento setup:upgrade

Features

Usage

Transforming an image from a template

Call the image helper from any front-end (.phtml) template using this code:

You can now call the make method to a relative image path or an image URL

Then, you can chain the desired transformation methods, and finally call the get method to get the http link to the cached image:

Or, you can do all of these at once with a short, chained syntax:

Enabling JPEG compression and setting the quality

JPEGs can be reduced in size by lowering the quality of the final output. PNGs will not be compressed, since they are a lossless format. From the template, call this method on the image helper to enable JPEG compression and set the quality (1-100, lowest to highest):

Clearing the image cache

Delete the image cache directory. By default, this is <magento root>/pub/media/cache/dakzilla_intervention To avoid potential permission issues, do not re-create this folder after deleting it. Let Magento re-create it automatically with the server permissions.

Available transformation methods

The helper provides IDE-compatible method hints for every available transformation method. For the most part, these methods are self-explanatory. For further information on these methods, please refer to the Intervention Image documentation.

Issues

Compatibility

This module has been tested with Magento 2.1 through 2.3. As Magento 2 is still evolving rapidly, there is no guarantee that it will work with every version. However, as this package is unassuming in what it achieves and respects Magento 2 best coding practices, I see no reason why it should cause issues in your installation.

Requirements

To-do

Thanks

This simple package is piggybacking on the incredible work of Oliver Vogel with his Intervention Image and Image Cache packages.

This module was also inspired by the awesome work of Stämpfli AG and their Magento 2 Image Resizer module.

License

This module is licensed under the MIT License

Copyright 2017 Simon Dakin

Made with ♥ in Montreal


All versions of intervention-image-helper with dependencies

PHP Build Version
Package Version
Requires php Version >=7.0.0
intervention/image Version ~2.3
jeremeamia/superclosure Version ^2.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package dakzilla/intervention-image-helper contains the following files

Loading the files please wait ....