$result = db_query("SELECT * FROM {imagecache_action}");
while ($row = db_fetch_array($result)) {
$data = unserialize($row['data']);
- // Keep scale and crop and the old scale function seperate... I don't really want to break BC with
- // the 2.x update. We'll deprecate this version.
+
+ // remove function from data if present;
$function = $data['function'];
unset($data['function']);
$data = serialize($data);
return false;
}
-
foreach ($actions as $action) {
if (!empty($action['data'])) {
// QuickSketch, why do these run first/twice? - dopry.
}
return false;
}
+
return true;
}
function imagecache_scale_and_crop_image(&$image, $data) {
- // Set impossibly large values if the width and height aren't set.
- $data['width'] = $data['width'] ? $data['width'] : 9999999;
- $data['height'] = $data['height'] ? $data['height'] : 9999999;
if (!imageapi_image_scale_and_crop($image, $data['width'], $data['height'])) {
watchdog('imagecache', t('imagecache_scale_and_crop failed. image: %image, data: %data.', array('%path' => $image, '%data' => print_r($data, true))), WATCHDOG_ERROR);
return false;
if ($may_cache) {
$items[] = array(
'path' => 'admin/build/imagecache',
- 'title' => t('Imagecache Presets'),
+ 'title' => t('Imagecache'),
'description' => t('Administer imagecache presets and actions.'),
'callback' => 'imagecache_ui_presets',
'access' => user_access('administer imagecache'),