<?php
$im = new Imagick();
if ($im->pingImage('1.jpg')) {
$image_info = $im->identifyImage();
print_r($image_info);
}
else {
echo 'image doesn't exist';
}
?>
If I pass to pingImage a real image name, then print_r shows an array with parameters. But if I pass to pingImage not a real image name, nothing happens, but I expect output of "image doesn't exist". At the same time if I add an echo output before the condition, this echo does work.
Generally code is working until pingImage return false.
I haven't find the answer in the Imagick documentation.