PHP | Imagick resetImagePage() Function Last Updated : 17 Dec, 2019 Summarize Comments Improve Suggest changes Share Like Article Like Report The Imagick::resetImagePage() function is an inbuilt function in PHP which is used to reset the image page. Syntax: bool Imagick::resetImagePage( string $page ) Parameters: This function accepts a single parameter $page which holds the page definition in form of WxH+x+y, where W is for width, H is for height, x is for x-coordinate and y is for y-coordinate. Return Value: This function returns TRUE on success. Exceptions: This function throws ImagickException on error. Below programs illustrate the Imagick::resetImagePage() 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'); // Reset the Image Page $imagick->resetImagePage('768x147+2+2'); // Get the Image Page $page = $imagick->getImagePage(); print("<pre>".print_r($page, true)."</pre>"); ?> Output: Array ( [width] => 768 [height] => 147 [x] => 2 [y] => 2 ) Program 2: php <?php // Create a new Imagick object $imagick = new Imagick( 'https://media.geeksforgeeks.org/wp-content/uploads/geeksforgeeks-13.png'); // Reset the Image Page $imagick->resetImagePage('800x300+1+1'); // Get the Image Page $page = $imagick->getImagePage(); print("<pre>".print_r($page, true)."</pre>"); ?> Output: Array ( [width] => 800 [height] => 300 [x] => 1 [y] => 1 ) Reference: https://www.php.net/manual/en/imagick.resetimagepage.php Comment More infoAdvertise with us Next Article PHP | Imagick setImageType() Function G gurrrung Follow Improve Article Tags : Web Technologies PHP PHP-function PHP-Imagick Similar Reads PHP | Imagick setImagePage() Function The Imagick::setImagePage() function is an inbuilt function in PHP which is used to set the image page geometry. Syntax: bool Imagick::setImagePage(int $width, int $height, int $x, int $y ) Parameters: This function accepts four parameters as mentioned above and described below: $width: It specifies 1 min read PHP | Imagick setImageType() Function The Imagick::setImageType() function is an inbuilt function in PHP which is used to set the image type.Syntax:Â Â bool Imagick::setImageType( int $image_type ) Parameters: This function accepts a single parameter $image_type which contains an integer value corresponding to one of IMGTYPE constants. W 1 min read PHP | Imagick resizeImage() Function The Imagick::resizeImage() function is an inbuilt function in PHP which is used to scale an image to the desired dimensions. Syntax: bool Imagick::resizeImage( int $columns, int $rows, int $filter, float $blur, bool $best_fit = false, bool $legacy = false ) Parameters: This function accepts six para 2 min read PHP | Imagick setPage() Function The Imagick::setPage() function is an inbuilt function in PHP which is used to set the page geometry of the Imagick object. Syntax: bool Imagick::setPage( int $width, int $height, int $x, int $y ) Parameters:This function accepts four parameters as mentioned above and described below: $width: It spe 2 min read PHP | Imagick remapImage() Function The Imagick::remapImage() function is an inbuilt function in PHP which is used to replace colors in an image with those defined by replacement. The colors are replaced with the closest possible color. Syntax: bool Imagick::remapImage( Imagick $replacement, int $dither ) Parameters:This function acce 2 min read PHP | Imagick removeImage() Function The Imagick::removeImage() function is an inbuilt function in PHP which is used to remove an image from the image list. This function removes the current image which is pointed by the cursor. Syntax: bool Imagick::removeImage( void ) Parameters: This function doesnât accepts any parameters. Return V 1 min read Like