public function exifFunc($image, $raw = false)
    {
        if (isset($this->grav['exif'])) {
            /** @var UniformResourceLocator $locator */
            $locator = $this->grav['locator'];

            if ($locator->isStream($image)) {
                $image = $locator->findResource($image);
            }

            $exif_reader = $this->grav['exif']->getReader();

            if ($image & file_exists($image) && $this->config->get('system.media.auto_metadata_exif') && $exif_reader) {

                $exif_data = $exif_reader->read($image);

                if ($exif_data) {
                    if ($raw) {
                        return $exif_data->getRawData();
                    }

                    return $exif_data->getData();
                }
            }
        }

        return null;
    }
public function exifFunc($image, $raw = false)
    {
        if (isset($this->grav['exif'])) {
            /** @var UniformResourceLocator $locator */
            $locator = $this->grav['locator'];

            if ($locator->isStream($image)) {
                $image = $locator->findResource($image);
            }

            $exif_reader = $this->grav['exif']->getReader();

            if ($image & file_exists($image) && $this->config->get('system.media.auto_metadata_exif') && $exif_reader) {

                $exif_data = $exif_reader->read($image);

                if ($exif_data) {
                    if ($raw) {
                        return $exif_data->getRawData();
                    }

                    return $exif_data->getData();
                }
            }
        }

        return null;
    }
public function exifFunc ( $ image , $ raw = false ) { if ( isset ( $ this -> grav [ 'exif' ] ) ) { /** @var UniformResourceLocator $locator */ $ locator = $ this -> grav [ 'locator' ] ; if ( $ locator -> isStream ( $ image ) ) { $ image = $ locator -> findResource ( $ image ) ; } $ exif_reader = $ this -> grav [ 'exif' ] -> getReader ( ) ; if ( $ image & file_exists ( $ image ) && $ this -> config -> get ( 'system.media.auto_metadata_exif' ) && $ exif_reader ) { $ exif_data = $ exif_reader -> read ( $ image ) ; if ( $ exif_data ) { if ( $ raw ) { return $ exif_data -> getRawData ( ) ; } return $ exif_data -> getData ( ) ; } } } return null ; }
Get's the Exif data for a file

@param string $image
@param bool $raw
@return mixed
Get s the Exif data for a file