Advertisement
Guest User

Yii - ImageCache

a guest
Nov 2nd, 2010
459
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 1.23 KB | None | 0 0
  1. <?php
  2. ...
  3. 'image'=>array(
  4.         'class'=>'ext.imageapi.CImage',
  5.         'presets'=>array(
  6.             '640x480'=>array(
  7.                 'cacheIn'=>'webroot.repository.640x480',
  8.                 'actions'=>array(
  9.                     'scaleAndCrop'=>array('width'=>640,    
  10.                                           'height'=>480),
  11.                     'watermark'=>array(
  12.                        'pngWatermark'=>'webroot.images.watermark.png',
  13.                         'x'=>590,'y'=>430),
  14.                 ),
  15.             ),
  16.             '100x75'=>array(
  17.                 'cacheIn'=>'webroot.repository.100x75',
  18.                 'actions'=>array(
  19.                     'scaleAndCrop'=>array('width'=>100, 'height'=>75),
  20.                     'watermark'=>array('pngWatermark'=>'/images/watermark.png', 'x'=>50,'y'=>25),
  21.                 ),
  22.             ),
  23.             '40x30'=>array(
  24.                 'cacheIn'=>'webroot.repository.40x30',
  25.                 'actions'=>array( 'scaleAndCrop'=>array('width'=>40, 'height'=>30) ),
  26.             ),
  27.             '27x20'=>array(
  28.                 'cacheIn'=>'webroot.repository.27x20',
  29.                 'actions'=>array( 'scaleAndCrop'=>array('width'=>27, 'height'=>20) ),
  30.             ),
  31.       ),
  32.     ),
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement