Questions tagged [intervention]

Intervention Image is an open source PHP image handling and manipulation library. It provides an easier and expressive way to create, edit, and compose images and currently supports the two most common image processing libraries GD Library and Imagick.

Intervention Image is an open source PHP image handling and manipulation library. It provides an easier and expressive way to create, edit, and compose images and currently supports the two most common image processing libraries GD Library and Imagick.

The class is written to make PHP image manipulating more easier and expressive. No matter if you want to create image thumbnails, watermarks or format large image files Intervention Image helps you to manage every task in an easy way with as little lines of code as possible.

The library follows the FIG standard PSR-2 to ensure a high level of interoperability between shared PHP code and is fully unit-tested.

456 questions
3
votes
7 answers

Intervention\Image\Exception\NotSupportedException Encoding format (tmp) is not supported

I am using the Intervention package with Laravel 5.6, the issue I am getting whenever I am uploading a file I have been presented with the error Encoding format(tmp) is not supported. I have my gdd2 extension enabled also. This is the code where I…
Debjit Roy
  • 35
  • 1
  • 1
  • 4
3
votes
1 answer

Laravel - Intervention Image - Image source not readable

I want to resize my images with Intervention Image package, but When I tried it gives me that error. Intervention \ Image \ Exception \ NotReadableException Image source not readable My codes; if ($request->hasFile('featured_image')) { …
user9334443
3
votes
3 answers

get error while file upload in laravel

I am trying to upload image in laravel. But when i upload it gives error. Call to a member function getClientOriginalExtension() on null Here is my Blade file form {{Form::open(array('url' => '/AddNewBlog','id'=>'blogadd' , 'method' =>…
Parth Sureliya
  • 255
  • 5
  • 19
3
votes
2 answers

How to upload large size image by Intervention Image in Laravel 5

I'm using Image Intervention in my project. My application working smoothly while uploading small size images. But when I try to upload large size image(>2mb), my application stops working! Even It shows no proper errors. Sometimes It shows Token…
S M Iftakhairul
  • 1,120
  • 2
  • 19
  • 42
3
votes
2 answers

Laravel 5 Store Image from URL

I'm trying to store an image from a URL using Intervention to my storage. Here is what I tried so far(Attempt 1): $path = 'http://f2b9x.s87.it/images/1/FR_laura-kithorizontal.gif'; $filename = basename($path); $image = Image::make($path); $store =…
Adam Silva
  • 1,013
  • 18
  • 48
3
votes
0 answers

Intervention - Resize - Quality

I am trying to resize images from 3000 * 4000 px with a size of 7 MB to images of height 650px. With intervention I am using the following steps. Image::configure(array('driver' => 'gd')); $img = Image::make($imgName); $img->resize(null,650,…
Lynn Rey
  • 231
  • 3
  • 17
3
votes
1 answer

Laravel + Image Intervention : Force download of file that is not saved

I want to simply upload files , resize them and then force a download for every uploaded file. I do not want to save the files. Resizing etc. works fine, however I cannot manage to force the download of the new file. $content =…
Frnak
  • 6,601
  • 5
  • 34
  • 67
3
votes
2 answers

Use laravel storage with Image intervention canvas()

Running Laraval 5.4 with Vagrant and Homestead. Saw a few other questions regarding this issue but none provided a solution which uses the canvas() method by Intervention/Image Laravel introduced a easier storage system since 5.3 My current…
Christophvh
  • 12,586
  • 7
  • 48
  • 70
3
votes
0 answers

Quality loss when uploading image with Laravel

I'm uploading an image using the below commands to Amazon S3: $image = Image::make($request->file('image'))->encode('jpg', 100); $image = $image->fit(1440, 768); $image->save('uploads/image.jpg'); $s3 =…
Alvin Bakker
  • 1,456
  • 21
  • 40
3
votes
4 answers

Can't write image data to path. Intervention Image Laravel 5.2

public function newItem(Request $request){ $image = $request->file('image'); $img = time().'.'.$image->getClientOriginalExtension(); $watermark = Image::make('images/watermark.png'); $destinationPath =…
Michel
  • 1,065
  • 1
  • 10
  • 25
3
votes
1 answer

creating image inside a folder results in creating an image with name folder/image.jpg

I have this piece of code: $file = $faker->image($dir = public_path().'/tmp', $width = 800, $height = 600, '', true); $hash = str_random(7); $thumbnailName = $hash . '.jpg'; $thumbnailImage = ImgResizer::make($file)->fit(180, 180); …
niko craft
  • 2,893
  • 5
  • 38
  • 67
3
votes
2 answers

Intervention: Resize image twice?

I want to resize an image twice using Intervention. I have this currently: $img = Image::make($image_url); $img_path = public_path() . '/images/'; $img->fit(500, 250); $img->save($img_path . '/img_250.jpg'); $img =…
user6421733
3
votes
2 answers

Laravel intervention/image resize is returning null. Laravel 5

I can't figure it out. When I resize the uploaded image like so, public function up(Request $request) { $user = $request->user(); $image= $request->file('images'); if(!empty(($image))){ $files = Input::file('images'); …
jackjoesmith
  • 951
  • 4
  • 20
  • 33
3
votes
4 answers

How do I resize image using intervention before storing to s3?

I'm saving the image to s3 and the s3 path to my database. I'm calling the path when I need to show the image. So right now I'm having trouble resizing that image before saving it to s3. I get this error message: Command (getRealPath) is not…
jackjoesmith
  • 951
  • 4
  • 20
  • 33
3
votes
0 answers

Intervention image blurry after resize

I've set the driver to 'imagick' and here's the code that resizes the image: Route::get('something', function() { $img = Image::make(storage_path('assets/someimage.jpg'))->resize(1000, null, function($cons){ $cons->aspectRatio(); …
Bravi
  • 713
  • 2
  • 8
  • 29