Description
array array_flip (array trans)
array_flip() returns a reversed array, for example, the key names in trans become values, and the values in trans become key names.
Note that the value in trans needs to be a legal key name, for example, it needs to be integer or string. A warning will be emitted if the value is of the wrong type, and the key/value pair in question will not be reversed.
If the same value appears multiple times, the last key name will be used as its value, and all others will be lost.
array_flip() returns FALSE if it fails.
Example: