image_path_flush
function image_path_flush
image_path_flush($path)
Clears cached versions of a specific file in all styles.
Parameters
$path: The Drupal file path to the original image.
File
- modules/image/image.module, line 548
- Exposes global functionality for creating image styles.
Code
function image_path_flush($path) { $styles = image_styles(); foreach ($styles as $style) { $image_path = image_style_path($style['name'], $path); if (file_exists($image_path)) { file_unmanaged_delete($image_path); } } }
© 2001–2016 by the original authors
Licensed under the GNU General Public License, version 2 and later.
Drupal is a registered trademark of Dries Buytaert.
https://api.drupal.org/api/drupal/modules!image!image.module/function/image_path_flush/7.x