Symfony2,Liipimaginebundle不起作用,不会创建文件夹和图像

时间:2014-12-09 23:34:16

标签: php symfony liipimaginebundle

我刚刚安装了liipimaginebundle,但它不起作用,也没有创建文件夹和图像

应用/配置/ routing.yml中:

_liip_imagine:
resource: "@LiipImagineBundle/Resources/config/routing.xml"

应用/配置/ config.yml:

liip_imagine:
resolvers:
   default:
      web_path: ~

filter_sets:
    cache: ~
    travelThumb:
        quality: 80
        filters:
            thumbnail: { size: [120, 90], mode: inset }

树枝

<img src="{{ travel.image.webPath | imagine_filter('travelThumb') }}" alt="{{ travel.image.alt }}" />

当我在浏览器中检查元素时,我得到了这段代码:

<img src="http://localhost/agence/web/app_dev.php/media/cache/resolve/travelThumb/uploads/img/travels/1.jpeg" alt="entry_big_1.jpg">

当我在新标签页中打开该链接检查元素时,我收到此错误:

PHP exif extension is required to use the ExifMetadataReader

1 个答案:

答案 0 :(得分:4)

此库需要PHP EXIF。您可以使用--enable-exif编译PHP。更多信息: http://php.net/manual/en/exif.installation.php