function image_replace_image_styles_alter in Image Replace 7
Implements hook_image_styles_alter().
Save image style name into replace effect settings in order to make the style name available from within image_replace_effect callback.
File
- ./
image_replace.module, line 252 - Provides an image style effect replacing the whole image with another one.
Code
function image_replace_image_styles_alter(&$styles) {
foreach ($styles as $image_style => $style) {
foreach ($style['effects'] as $ieid => $effect) {
if ($effect['name'] == 'image_replace') {
$styles[$image_style]['effects'][$ieid]['data']['image_style'] = $image_style;
}
}
}
}