Filters dimensions to constrain down-sampled images to.
$orig_w, $orig_h, $dest_w, $dest_h, $crop = false
Sortie :
@param int[] $dimensions {
@param int $current_width The current width of the image.
@param int $current_height The current height of the image.
@param int $max_width The maximum width permitted.
@param int $max_height The maximum height permitted.
@param int $orig_w Original width in pixels.
@param int $orig_h Original height in pixels.
@param int $dest_w New width in pixels.
@param int $dest_h New height in pixels.
@param bool|array $crop {
@return array|false Returned array matches parameters for `imagecopyresampled()`. False on failure.
// Utilisation de la fonction image_resize_dimensions
$result = image_resize_dimensions($orig_w, $orig_h, $dest_w, $dest_h, $crop = false);
if ($result) {
// Votre logique ici
}
Chargement des actualités...