image_make_intermediate_size [ WordPress Function ]
| Parameters: |
|
| Returns: |
|
| Defined at: |
|
Resize an image to make a thumbnail or intermediate size.
The returned array has the file size, the image width, and image height. The filter 'image_make_intermediate_size' can be used to hook in and change the values of the returned array. The only parameter is the resized file path.
Source
<?php
function image_make_intermediate_size($file, $width, $height, $crop=false) {
if ( $width || $height ) {
$resized_file = image_resize($file, $width, $height, $crop);
if ( !is_wp_error($resized_file) && $resized_file && $info = getimagesize($resized_file) ) {
$resized_file = apply_filters('image_make_intermediate_size', $resized_file);
return array(
'file' => wp_basename( $resized_file ),
'width' => $info[0],
'height' => $info[1],
);
}
}
return false;
}
?>
Examples [ wp-snippets.com ]
Google Arama Sonuçlarý
- Function Reference/image make intermediate size - WordPress Codex
The filter 'image_make_intermediate_size' can be used to hook in and change the values of the returned array. The only parameter is the resized file path.
codex.wordpress.org - WordPress › Support » image_make_intermediate_size
Hello,. I just realized there is a way to get medium sized images to be zoomcropped to fit the exact measurements you set in your WordPress options. Now, I'd ...
wordpress.org - image_make_intermediate_size Wordpress hook details -- Adam ...
WordPress hook directory image_make_intermediate_size. WordPress version history for image_make_intermediate_size. This database has information for all ...
adambrown.info - image_make_intermediate_size | A HitchHackers guide through ...
Feb 12, 2011 ... function image_make_intermediate_size($file, $width, $height, $crop=false) { if ( $width || $height ) { $resized_file = image_resize($file, $width, ...
hitchhackerguide.com