| 5 image.inc | image_resize($source, $destination, $width, $height) |
| 6 image.inc | image_resize( |
| 7 image.inc | image_resize(stdClass $image, $width, $height) |
| 8 image.inc | image_resize(stdClass $image, $width, $height) |
Resize an image to the given dimensions (ignoring aspect ratio).
Parameters
$image: An image object returned by image_load().
$width: The target width, in pixels.
$height: The target height, in pixels.
Return value
TRUE on success, FALSE on failure.
See also
Related topics
4 calls to image_resize()
2 string references to 'image_resize'
File
- core/
includes/ image.inc, line 279 - API for manipulating images.
Code
function image_resize(stdClass $image, $width, $height) {
$width = (int) round($width);
$height = (int) round($height);
return image_toolkit_invoke('resize', $image, array($width, $height));
}
Login or register to post comments