A
A
andrewnsk2017-06-07 09:25:41
Zend Framework
andrewnsk, 2017-06-07 09:25:41

How does server side image caching work in zend framework 2?

Hello.
In general, when I upload a file for the slider, it is placed at
\upload\gaufrette\e\6\5\e65b5dca1c575eee3efadb509861013bd0725312\IMG.jpeg
And then after the slider starts to display it, zf will convert it to the file
\cache\htimg\mt- slides\upload\gaufrette\e\6\5\e65b5dca1c575eee3efadb509861013bd0725312\
IMG.jpeg.png the file is converted to png format. Even if I upload a png file of the size it converts the image to, it still converts it by adding a second extension. I don't like the result of the conversion.
Is there a way to turn off image conversions?
module\MtSlides\config\module.config.php

return [
    
  
    'htimg' => [
        'filters' => [
            'mt-slides' => [
                'type' => 'thumbnail',
                'options' => [
                    'width' => 1170,
                    'height' => 800,
                    'format' => 'jpeg'
                ]
            ],
        ],
    ],
//...

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question