(PECL imagick 2, PECL imagick 3)
Imagick::queryFormats — Returns formats supported by Imagick
public static Imagick::queryFormats ([ string $pattern = "*" ] ) : array
Returns formats supported by Imagick.
pattern
Returns an array containing the formats supported by Imagick.
Throws ImagickException on error.
Example #1 Imagick::queryFormats()
<?php function render() { $output = ""; $input = \Imagick::queryformats(); $columns = 6; $output .= "<table border='2'>"; for ($i=0; $i < count($input); $i += $columns) { $output .= "<tr>"; for ($c=0; $c<$columns; $c++) { $output .= "<td>"; if (($i + $c) < count($input)) { $output .= $input[$i + $c]; } $output .= "</td>"; } $output .= "</tr>"; } $output .= "</table>"; return $output; } ?>
© 1997–2020 The PHP Documentation Group
Licensed under the Creative Commons Attribution License v3.0 or later.
https://www.php.net/manual/en/imagick.queryformats.php