I created an imagecache preset using the scale and crop method and then set the rotor view to use that preset and also set the rotor size to match. I then added the block to a panel. The image displays, but it's displaying the full sized original (just clipped to the rotor size) not the preset. It also never generated the derivatives. Nor is there any way in the rotor content type settings to force a size limit, so I've got no way to get it to display the image at the correct size. Here's the view export code:
$view = new view;
$view->name = 'rotor';
$view->description = 'Default view for the Botor Banner module - A block that rotates through all Rotor Items';
$view->tag = '';
$view->view_php = '';
$view->base_table = 'node';
$view->is_cacheable = FALSE;
$view->api_version = 2;
$view->disabled = FALSE; /* Edit this to true to make a default view disabled initially */
$handler = $view->new_display('default', 'Defaults', 'default');
$handler->override_option('fields', array(
'body' => array(
'label' => 'Body',
'exclude' => 0,
'id' => 'body',
'table' => 'node_revisions',
'field' => 'body',
'relationship' => 'none',
),
));
$handler->override_option('filters', array(
'status' => array(
'operator' => '=',
'value' => 1,
'group' => '0',
'exposed' => FALSE,
'expose' => array(
'operator' => FALSE,
'label' => '',
),
'id' => 'status',
'table' => 'node',
'field' => 'status',
'override' => array(
'button' => 'Override',
),
'relationship' => 'none',
),
'type' => array(
'operator' => 'in',
'value' => array(
'rotor_item' => 'rotor_item',
),
'group' => '0',
'exposed' => FALSE,
'expose' => array(
'operator' => FALSE,
'label' => '',
),
'id' => 'type',
'table' => 'node',
'field' => 'type',
'relationship' => 'none',
),
));
$handler->override_option('access', array(
'type' => 'none',
));
$handler->override_option('style_plugin', 'rotor');
$handler->override_option('style_options', array(
'width' => '456',
'height' => '515',
'seconds' => '5',
'speed' => '2',
'effect' => 'fade',
'pause' => 1,
'tabs' => array(
'show_tabs' => 0,
'group_tabs' => '',
'position' => '0',
),
));
$handler->override_option('row_plugin', 'unformatted');
$handler->override_option('row_options', array(
'imagecache_preset' => '1',
));
$handler = $view->new_display('block', 'Block', 'block_1');
$handler->override_option('block_description', '');
$handler->override_option('block_caching', -1);
Any ideas? Similar settings worked just fine on another server, but we actually built these two servers to be virtually identical, so I have no idea what's going on.
Comments
Comment #1
seanrBTW, I should also note, when I go to the image cache preset configuration, it actually does scale the Druplicon just fine, so it's not an imagecache problem. Looks like Rotor is failing to request the correct image preset.
Comment #2
dddave commentedSame problem here (but I use the 2.0 version and display the block in a region and not a panel). Just stumbled uppon it and was about to create a new issue.
Checked the files and couldn't locate the pics in the imagecache preset folders (but they were uploaded correctly into the rotor folder).
Comment #3
mrfelton commentedpublic or private file system?
@dddave: please try with latest -dev just to be sure (there are quite a few important fixes there anyway)
Comment #4
dddave commentedThe dev-version works like a charm. I can change the imagecache presets and they are applied correctly. Great work!
Comment #5
madhan mohan commentedI also faced the same problem... the Newer version has some bugs. so for better functionality and working imagecache use imagecache 6.x-2.0-beta8 version and ImageAPI 6.x-1.3
Comment #6
dddave commentedI just checked if the imagecache stuff works. I am using imagecache beta9 and ImageAPI 1.6. I am gonna to give it a more intense look during the day.
Comment #7
mrfelton commentedUpon trying to test this bug, I'm having some real problems with the latest ImageCache (possibly related to #371195: Images being created in the wrong folder) which is making testing impossible. @madhanmohan: thanks for the top, I'll try that now.
Can anyone else confirm if all is good in the -dev release?
Comment #8
mrfelton commentedfor me -dev is working just fine with ImageCache 6.x-2.0-beta8 version and ImageAPI 6.x-1.3 (later versions on ImageCache/ImageAPI seem to be a little broken)
Comment #9
madhan mohan commentedWe have a live site which works with beta version 8 imagecache
Regadrs & Thanks,
Madhan Mohan R
http://madhan-drupal.blogspot.com
Comment #10
mrfelton commentedSo do I!!. but, on a brand new install, it doesn't work out of the box anymore.
EDIT: (with ImageCache beta-9)
Comment #11
mrfelton commentedComment #14
kinosura commentedI have fixed the same problem with Imagecache 6.x-2.0-beta10 and ImageAPI 6.x-1.6 by setting the Temporary directory (tmp) on the File system page after Imagecache upgrade. Looks like this setting has been removed or smth like this.