mirror of
https://github.com/mosbth/cimage.git
synced 2025-10-22 19:36:39 +02:00
adding support for pngquant
This commit is contained in:
@@ -163,3 +163,24 @@ function verbose($msg = null)
|
||||
|
||||
$log[] = $msg;
|
||||
}
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Log when verbose mode, when used without argument it returns the result.
|
||||
*
|
||||
* @param string $msg to log.
|
||||
*
|
||||
* @return void or array.
|
||||
*/
|
||||
function checkExternalCommand($what, $enabled, $commandString)
|
||||
{
|
||||
$no = $enabled ? null : 'NOT';
|
||||
$text = "Post processing $what is $no enabled.<br>";
|
||||
|
||||
list($command) = explode(" ", $commandString);
|
||||
$no = is_executable($command) ? null : 'NOT';
|
||||
$text .= "The command for $what is $no an executable.<br>";
|
||||
|
||||
return $text;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user