function image_imageinfo_cache_save in Imageinfo Cache 7.3
Writes an image resource to a destination file.
Parameters
object $image: An image object.
string $destination: A string file URI or path where the image should be saved.
Return value
bool TRUE or FALSE, based on success.
See also
2 string references to 'image_imageinfo_cache_save'
- imageinfo_cache_hooks in ./
imageinfo_cache.module - Output an array of modules that use imageinfo cache hooks.
- imageinfo_cache_hook_info in ./
imageinfo_cache.module - Implements hook_hook_info().
File
- ./
imageinfo_cache.toolkit.inc, line 265 - Imageinfo Cache module. Pseudo image toolkit functions.
Code
function image_imageinfo_cache_save($image, $destination) {
// Change toolkit back to the original value.
$image->toolkit = variable_get('image_toolkit_original', 'gd');
$return = image_toolkit_invoke('save', $image, array(
$destination,
));
// Call hook_image_imageinfo_cache_save($image, $destination, $return);
module_invoke_all('image_imageinfo_cache_save', $image, $destination, $return);
// Change toolkit to the pseudo value again.
$image->toolkit = variable_get('image_toolkit', 'gd');
return $return;
}