liipimaginebundle

Update and remove cached image using Liipimaginebundle

寵の児 提交于 2019-12-05 17:27:45
I'm using liipimaginebundle and everything work fine except for deletion and update cached images when I update the original image. I would to know How can I do this config.yml liip_imagine: resolvers: default: web_path: ~ filter_sets: cache: ~ travel_75_55: quality: 80 filters: thumbnail: { size: [75, 55], mode: outbound } travel_270_161: quality: 75 filters: thumbnail: { size: [270, 161], mode: outbound} And this is Entity: Image /** * Image * * @ORM\HasLifecycleCallbacks */ class Image { //................. public $file; public function setFile($file) { $this->file = $file; if (null !==

Installing and running LiipImagineBundle in symfony 2.1

大憨熊 提交于 2019-12-04 09:50:22
Here are the steps I followed: Added following in my composer.json: "require": { "imagine/Imagine": ">=0.2.8", "liip/imagine-bundle": "*@dev", .... } Ran following command at command line: composer update Installing imagine/imagine (v0.4.0) Installing liip/imagine-bundle (dev-master f7d5e4d) After composer update my directory structure inside vendor folder looks like as below: Then update vendor/composer/autoload_namespaces.php 'Imagine' => $vendorDir .'/imagine/Imagine/lib/', 'Liip\\ImagineBundle'=>$vendorDir . '/liip/imagine-bundle/', Registered bundle: new Liip\ImagineBundle

Use LiipImagineBundle to Resize Image after Upload?

寵の児 提交于 2019-11-27 19:08:12
I'm using the LiipImagineBundle with Symfony 2.1 and would like to resize user uploaded images upon upload before saving them to the permanent filesystem location (to strip metadata, impose jpeg format, and limit the size of the file). I have to call a 'strip' and 'resize' filter from the controller and then save the filtered image from a temporary location to a folder of my choosing in the filesystem. I tried to use the LiipImageBundle Controller as a service as indicated in the bundle's readme but the called Action is mainly for creating a filtered image in the cache directory when a request