PHP | imagesy() Function Last Updated : 23 Aug, 2019 Comments Improve Suggest changes Like Article Like Report The imagesy() function is an inbuilt function in PHP which is used to return the height of the given image. Syntax: int imagesy( $image ) Parameters: This function accepts single parameters $image which is mandatory. This $image variable store the image created by imagecreatetruecolor() image creation function. Return Value: This function returns the height of the image or FALSE on errors. Below programs illustrate the imagesy() function in PHP. Program 1: php <?php // store the image in variable. $image = imagecreatefrompng("gfg.png"); // Display the height of image. echo imagesy($image); ?> Output: 184 Program 2: php <?php // Create the size of image or blank image. $image = imagecreatetruecolor(500, 300); // Display the height of image. echo imagesy($image); ?> Output: 300 Related Articles: PHP | imagedashedline() Function PHP | imagecolorat() function PHP | imagepolygon() Function Reference: http://php.net/manual/en/function.imagesy.php Comment More infoAdvertise with us Next Article PHP | imagesy() Function V vijay_raj Follow Improve Article Tags : Misc Web Technologies PHP PHP-function Practice Tags : Misc Similar Reads PHP | imagesx() Function The imagesx() function is an inbuilt function in PHP which is used to return the width of the given image. Syntax: int imagesx( $image ) Parameters: This function accepts single parameters $image which is mandatory. This $image variable can store the image created by imagecreatetruecolor() image cre 1 min read PHP | imagecopy() Function The imagecopy() function is an inbuilt function in PHP which is used to copy the image or part of image. This function returns true on success or false on failure. Syntax: bool imagecopy ( $dst_image, $src_image, $dst_x, $dst_y, $src_x, $src_y, $src_w, $src_h ) Parameters: This function accepts eigh 2 min read PHP | imagegd() function The imagegd() function is an inbuilt function in PHP which is used to output GD image to browser or file. This is most useful to convert any other image type to gd. imagecreatefromgd() function can be used to further read gd images. Syntax: bool imagegd( resource $image, float $to) Parameters:This 2 min read PHP | imagedestroy() Function The imagedestroy() function is an inbuilt function in PHP which is used to destroy an image and frees any memory associated with the image. Syntax: bool imagedestroy( resource $image ) Parameters: This function accepts a single parameter $image which holds the name of image. Return Value: This funct 1 min read PHP | imagepng() Function The imagepng() function is an inbuilt function in PHP which is used to display image to browser or file. The main use of this function is to view an image in the browser, convert any other image type to PNG and applying filters to the image. Syntax: bool imagepng( resource $image, int $to, int $qual 2 min read PHP | imagexbm() Function The imagexbm() function is an inbuilt function in PHP which is used to display image to browser a file. The main use of this function is to view an image in the browser and convert any other image type to XBM. Syntax: bool imagexbm( resource $image, int $to, int $foreground) Parameters: This functio 2 min read PHP | imagetypes() Function The imagetypes() function is an inbuilt function in PHP which is used to return the image types supported by the PHP inbuilt installed library. Syntax: int imagetypes( void ) Parameters: This function does not accept any parameter. Return Value: This function returns the bit-field corresponding to t 1 min read PHP | imagegif() Function The imagegif() function is an inbuilt function in PHP which is used to create the GIF image file from the given image. If the image has been made transparent with imagecolortransparent() function, then GIF89a image format will generate otherwise GIF87a image format will generate. Syntax: bool imageg 2 min read PHP | imagegd2() Function The imagegd2() function is an inbuilt function in PHP which is used to output GD2 image to browser or file. This is most useful to convert any other image type to gd2. The imagecreatefromgd2() function can be used to further read gd2 images. Syntax: bool imagegd2( resource $image, float $to, int $ch 2 min read PHP | imagejpeg() Function The imagejpeg() function is an inbuilt function in PHP which is used to display image to browser or file. The main use of this function is to view an image in the browser, convert any other image type to JPEG and altering the quality of the image. Syntax: bool imagejpeg( resource $image, int $to, in 2 min read Like