Download the PHP package newism/craft-imgix without Composer

On this page you can find all versions of the php package newism/craft-imgix. 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 craft-imgix

Imgix Asset Transformer for Craft CMS

Adds imgix powered asset transforms to Craft CMS:

  1. Drop-in replacement for Craft CMS native image transforms and .srcset() method
  2. Add additional imgix parameters to image transforms
  3. Use imgix for CP thumbnails
  4. Allows .pdf files to be rasterized and transformed (unlike Craft CMS transforms)

The only thing you'll need to update is your filesystem Base URL to use your imgix domain.

Requirements

This plugin requires Craft CMS 4.0.0 or later, and PHP 8.0.2 or later.

See Caveats for additional requirements.

Installation

You can install this plugin with Composer.

Then update your filesystem Base URL to use your imgix domain.

Configuration

Copy config.php into Crafts config folder and rename it to newism-imgix.php.

Update the imgixDomain settings key with your imgix domain.

twig {# Set the transform #} {% do asset.setTransform({ ratio: 16/9, }) %}

{# Render the tag #} {{ tag('img', { src: asset.url, width: asset.width, height: asset.height, srcset: asset.getSrcset(['1.5x', '2x', '3x']), alt: asset.title, }) }} twig {# Set the transform #} {% do asset.setTransform({ width: 300, height: 300, imgix: { blur: 20, }, }) %}

{# Render the tag #} {{ tag('img', { src: asset.url, width: asset.width, height: asset.height, srcset: asset.getSrcset(['1.5x', '2x', '3x']), alt: asset.title, }) }}



### Caveats

#### .svg

imgix does not support rasterizing .svg inputs by default ([blog post](https://www.imgix.com/blog/announcing-support-for-webp-and-svg)).
You will need to contact imgix to enable this feature. This plugin does add transform query parameters to .svg files regardless of this setting.

#### .pdf
.pdf file are served with `rasterize-bypass` set to true when no transform is provided. This will serve the original .pdf file.

> The `rasterize-bypass` parameter allows users to bypass all rendering parameters, including default parameters, and serve the original image file. This is particularly useful for file formats that support vector graphics and do not require rasterization. [Source](https://docs.imgix.com/en-US/apis/rendering/format/rasterize-bypass)

#### `imgix` object key values

In Craft CMS < v5.6.0 the additional `imgix` object key values are lost
when calling [.srcset()](https://craftcms.com/docs/5.x/development/image-transforms.html#generating-srcset-sizes).

All versions of craft-imgix with dependencies

PHP Build Version
Package Version
Requires craftcms/cms Version ^4.0|^5.6.0
imgix/imgix-php Version ^4.1
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 newism/craft-imgix contains the following files

Loading the files please wait ....