2017 © Pedro Peláez
 

library image

A forked Laravel 4 to 5.1. package to aid generating automatically resized images on the fly and generating responsive images.

image

marcha/image

A forked Laravel 4 to 5.1. package to aid generating automatically resized images on the fly and generating responsive images.

  • Wednesday, August 5, 2015
  • by marcha
  • Repository
  • 1 Watchers
  • 3 Stars
  • 92 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 14 Forks
  • 0 Open issues
  • 10 Versions
  • 0 % Grown

The README.md

Image

A Laravel 4-5 wrapper for the Imagecow image resizing / respoisive image package. See [https://github.com/oscarotero/imageCow][1] for more detail on the underlying image manipulation package., (*1)

Image cow can use either GD or ImageMagick to transform image., (*2)

Instalation

Install as any other Laravel 4 package:, (*3)

1) Add to composer:, (*4)

"require": {
    ...
    "marcha/image":"dev-master"
    ...
}

2) Composer Update:, (*5)

$ composer update

3) Add to the providers array in app.php:, (*6)

    'providers' => array(

    ...

    'marcha\Image\Providers\Laravel\ImageServiceProvider'
)

4) Add to the facades array in app.php:, (*7)

    'aliases' => array(

    ...

    'Image' => 'marcha\Image\Providers\Laravel\Facades\Image'
)

5) Publish the package config file to change the defaults:, (*8)

$ php artisan vendor:publish marcha/image

6) Copy the /vendor/imagecow/imagecow/Imagecow/Imagecow.js file to a publicly accessible web directory. The default path is set as /public/js/Imagecow.js, but whatever it is set as in the config the file must exist., (*9)

7) Create folder storage/cache/images, (*10)

Usage

Standard

To provide image links on your templates use like so:, (*11)

<img src="{{ Image::path('/image.jpg', 'resizeCrop', 400, 200) }}" />

Where the first argument is the image which is referenced from the root of the public directory. The second argument is the transform method and each subsequent argument is an argument that would be passed to the relevant transform method used. See the Imagecow Documentation for more details., (*12)

Responsive

To provide links to responsive images use a similar syntax:, (*13)

<img src="{{ Image::path('/image.jpg', 'resizeCrop', 400, 200)->responsive('max-width=400', 'resize', 100) }}" />

The first argument is the "rule" and the subsequent arguments are the transform conditions to apply to that rule, following the same format. You can apply multiple responsive breakpoints by calling responsive multiple times., (*14)

Caching

All images are cached automatically, they are cached to the filesystem in the storage directory, the exact path and lifetime of the cache are configurable in the package config., (*15)

The Versions

05/08 2015

dev-master

9999999-dev

A forked Laravel 4 to 5.1. package to aid generating automatically resized images on the fly and generating responsive images.

  Sources   Download

The Requires

 

The Development Requires

by Kevin Baldwyn
by Nikola Janković

laravel laravel 4 responsive image resize laravel 5.1 imagecow

04/08 2015

2.0.5.x-dev

2.0.5.9999999-dev

A forked Laravel 4 to 5.1. package to aid generating automatically resized images on the fly and generating responsive images.

  Sources   Download

The Requires

 

The Development Requires

by Kevin Baldwyn
by Nikola Janković

laravel laravel 4 responsive image resize laravel 5.1 imagecow

05/03 2015

2.0.4

2.0.4.0

A Laravel 4 package to aid generating automatically resized images on the fly and generating responsive images.

  Sources   Download

The Requires

 

The Development Requires

by Kevin Baldwyn

laravel laravel 4 responsive image resize imagecow

02/12 2014

2.0.3

2.0.3.0

A Laravel 4 package to aid generating automatically resized images on the fly and generating responsive images.

  Sources   Download

The Requires

 

The Development Requires

by Kevin Baldwyn

laravel laravel 4 responsive image resize imagecow

04/08 2014

2.0.1

2.0.1.0

A Laravel 4 package to aid generating automatically resized images on the fly and generating responsive images.

  Sources   Download

The Requires

 

The Development Requires

by Kevin Baldwyn

laravel laravel 4 responsive image resize imagecow

04/08 2014

2.0.2

2.0.2.0

A Laravel 4 package to aid generating automatically resized images on the fly and generating responsive images.

  Sources   Download

The Requires

 

The Development Requires

by Kevin Baldwyn

laravel laravel 4 responsive image resize imagecow

11/07 2014

2.0

2.0.0.0

A Laravel 4 package to aid generating automatically resized images on the fly and generating responsive images.

  Sources   Download

The Requires

 

The Development Requires

by Kevin Baldwyn

laravel laravel 4 responsive image resize imagecow

25/06 2014

2.0.x-dev

2.0.9999999.9999999-dev

A Laravel 4 package to aid generating automatically resized images on the fly and generating responsive images.

  Sources   Download

The Requires

 

The Development Requires

by Kevin Baldwyn

laravel laravel 4 responsive image resize imagecow

09/05 2014

1.1.x-dev

1.1.9999999.9999999-dev

A Laravel 4 package to aid generating automatically resized images on the fly and generating responsive images.

  Sources   Download

The Requires

 

by Kevin Baldwyn

laravel laravel 4 responsive image resize imagecow

30/12 2013

1.0.x-dev

1.0.9999999.9999999-dev

A Laravel 4 package to aid generating automatically resized images on the fly and generating responsive images.

  Sources   Download

The Requires

 

by Kevin Baldwyn

laravel laravel 4 responsive image resize imagecow