open — Read a new image resource from file

Description

public Intervention\Image\Image open($path)

Read image from path in filesystem as image resource for current image.

If you want to create an image resource with a static call, use Image::make instead.

Parameters

path

Path of the image in filesystem.

Return Values

Instance of Intervention\Image\Image

Examples

  1. // create a image instance and open file
  2. $img = new Image;
  3. $img->open('public/foo.jpg');

See also