PHP array utility functions.
This is a set of utility functions for array alteration and handling., (*1)
They all follow the same naming conventions as the default methods in the form of array_*., (*2)
Functions
array_delete(array &$array, $key)
Deletes entry from array and return its value., (*3)
NB: This method modifies the original variable., (*4)
array_get(array $array, $key)
Lookup entry in array by key and return its value, returns false if not found., (*5)
array_flatten(array $array)
Make multidimensional array flat., (*6)
array_pick(array $array, $keys[, $key[, $key]])
Return array with only the keys in $keys., (*7)
array_reject(array $array, $keys[, $key[, $key]])
Return array without the keys in $keys.
This is the inverse of array_pick, (*8)
Contributing
- Fork it ( https://github.com/fetch/php-array-utils/fork )
- Create your feature branch (
git checkout -b my-new-feature)
- Commit your changes (
git commit -am 'Add some feature')
- Push to the branch (
git push origin my-new-feature)
- Create a new Pull Request