Return to Snippet

Revision: 32513
at September 27, 2010 14:30 by karmacode


Initial Code
function icye_site_imagecache_default_presets(){
  $presets = array();
  $path = drupal_get_path('module', 'icye_site') . '/imagecache';
  $files = drupal_system_listing('.inc$', $path, 'name', 0);
  foreach ($files as $file) {
    include_once $file->filename;
  }
  return $presets;
}


$presets['site_logo'] = array (
  'presetname' => 'site_logo',
  'actions' => 
  array (
    0 => 
    array (
      'weight' => '0',
      'module' => 'imagecache',
      'action' => 'imagecache_scale_and_crop',
      'data' => 
      array (
        'width' => '12%',
        'height' => '12%',
      ),
    ),
  ),
);

Initial URL


Initial Description
have multiple imagecache files be recognized as default

Initial Title
imagecache default presets

Initial Tags
drupal

Initial Language
PHP