Article Categories
- All Categories
-
Data Structure
-
Networking
-
RDBMS
-
Operating System
-
Java
-
MS Excel
-
iOS
-
HTML
-
CSS
-
Android
-
Python
-
C Programming
-
C++
-
C#
-
MongoDB
-
MySQL
-
Javascript
-
PHP
Selected Reading
imageflip() function in PHP
The imageflip() function is used to flip an image using given mode.
Syntax
bool imageflip(img, mode )
Parameters
img: An image resource created using imagecreatetruecolor()
mode: The flip mode. Here are the possible values:
IMG_FLIP_HORIZONTAL – Flips the image horizontally.
IMG_FLIP_VERTICAL – Flips the image vertically.
IMG_FLIP_BOTH – Flips the image both horizontally and vertically.
Return
The imageflip() function returns TRUE on success or FALSE on failure.
Example
The following is an example that flips an image horizontally:
Output
The following is the output:

Advertisements
