$im = new Imagick($file);
$im->setImageFormat('jpg');
$im->resizeImage(100, 100, 1, 0);
header("Content-Type: image/jpeg");
echo $im->getImageBlob();
exit;
$arr = [
'bar' => array(1, 2, 3, 4),
'foo' => array(2, 3, 4),
'kuu' => array(3, 4),
];
print_r(array_reverse($arr));
Array
(
[kuu] => Array
(
[0] => 3
[1] => 4
)
[foo] => Array
(
[0] => 2
[1] => 3
[2] => 4
)
[bar] => Array
(
[0] => 1
[1] => 2
[2] => 3
[3] => 4
)
)