Hi everybody,
I'm just starting to use the find_or_create_alternate() method to make
thumbnails, and I must be doing something wrong. When I try something
like this:
my $size = 240;
my $thumb = $pic->find_or_create_alternate({
title_prefix => '',
title_suffix => '-' . $size,
file_suffix => '_sized_nicely,
et_key_name => 'auto_generated_image',
relate => 0,
transformer => sub {
shift->scale( xpixels => $element_names_and_sizes{$size} );
},
});
...no new media document is created, and the $thumb returned is the
original $pic. Any idea what I'm doing incorrectly?
Thanks,
Bret
--
Bret Dawson
Producer
Pectopah Productions Inc.
(416) 895-7635
bret@pectopah.com
www.pectopah.com
I'm just starting to use the find_or_create_alternate() method to make
thumbnails, and I must be doing something wrong. When I try something
like this:
my $size = 240;
my $thumb = $pic->find_or_create_alternate({
title_prefix => '',
title_suffix => '-' . $size,
file_suffix => '_sized_nicely,
et_key_name => 'auto_generated_image',
relate => 0,
transformer => sub {
shift->scale( xpixels => $element_names_and_sizes{$size} );
},
});
...no new media document is created, and the $thumb returned is the
original $pic. Any idea what I'm doing incorrectly?
Thanks,
Bret
--
Bret Dawson
Producer
Pectopah Productions Inc.
(416) 895-7635
bret@pectopah.com
www.pectopah.com