PHP | Imagick getImageSize() Function Last Updated : 22 Nov, 2019 Comments Improve Suggest changes Like Article Like Report The Imagick::getImageSize() function is an inbuilt function in PHP which is used to get the image length in bytes. Syntax: int Imagick::getImageSize( void ) Parameters: This function doesn’t accepts any parameter. Return Value: This function returns an integer value containing the current image size. Below programs illustrate the Imagick::getImageSize() function in PHP: Program 1: php <?php // Create a new imagick object $imagick = new Imagick( 'https://media.geeksforgeeks.org/wp-content/uploads/geeksforgeeks-13.png'); // Get the Image Size $size = $imagick->getImageSize(); echo 'Image size is '. $size . ' bytes.'; ?> Output: Image size is 45435 bytes. Program 2: php <?php // Create a new imagick object $imagick = new Imagick( 'https://media.geeksforgeeks.org/wp-content/uploads/20190918234528/colorize1.png'); // Get the Image Size $size = $imagick->getImageSize(); echo 'Image size is '. $size . ' bytes.'; ?> Output: Image size is 36283 bytes. Reference: https://www.php.net/manual/en/imagick.getimagesize.php Comment More infoAdvertise with us Next Article PHP | Imagick getImageSize() Function G gurrrung Follow Improve Article Tags : Web Technologies PHP PHP-function PHP-Imagick Similar Reads PHP | Imagick getImageScene() Function The Imagick::getImageScene() function is an inbuilt function in PHP which is used to get the image scene of an Imagick object. Syntax: int Imagick::getImageScene( void ) Parameters: This function does not accept any parameter. Return Value: This function returns the image scene. Below programs illus 1 min read PHP | Imagick getSize() Function The Imagick::getSize() function is an inbuilt function in PHP which is used to get the size associated with the imagick object. Syntax: array Imagick::getSize( void ) Parameters: This function doesnât accepts any parameter. Return Value: This function returns an array with the keys "columns" and "ro 1 min read PHP | Imagick getImageType() Function The Imagick::getImageType() function is an inbuilt function in PHP which is used to get the potential image type. Syntax: int Imagick::getImageType( void ) Parameters: This function doesnât accepts any parameter. Return Value: This function returns an integer value corresponding to one of IMGTYPE co 1 min read PHP | Imagick getImagePage() Function The Imagick::getImagePage() function is an inbuilt function in PHP which is used to get the page geometry of a particular image. Syntax: array Imagick::getImagePage( void ) Parameters: This function does not accepts any parameter. Return Value: This function returns an array associated with the page 2 min read PHP | Imagick getImageWidth() Function The Imagick::getImageWidth() function is an inbuilt function in PHP which is used to get the width of the image. Syntax: int Imagick::getImageWidth( void ) Parameters: This function does not accepts any parameters. Return Value: This function returns the image width in pixels. Original Image Below p 1 min read Like