Answer the question
In order to leave comments, you need to log in
How to configure liip_imagine in Symfony?
How to configure liip_imagine in Symfony?
Really already boiled up.
It's not even a matter of how to set it up.
Here is the basic configuration.
liip_imagine:
resolvers:
default:
web_path:
web_root: '%kernel.project_dir%'
cache_prefix: 'media/cache'
loaders:
default:
filesystem:
data_root: '%kernel.project_dir%'
filter_sets:
# Prototype
xs:
cache: ~
filters:
relative_resize:
widen: 200
foreach ($series as $item) {
$imagePath = sprintf("%s/%s", $this->getParameter("app.media_dir.series"), $item->getImage());
if (!$cacheManager->isStored($imagePath, "xs")) {
try {
$bin_data = $dataManager->find("xs", $imagePath);
$filtered_bin_data = $filterManager->applyFilter($bin_data, "xs");
$cacheManager->store($filtered_bin_data, $imagePath, "xs");
} catch (Exception $exception) {
$e = $exception;
}
}
}
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question