WireRandom::arrayKeys() method
Get a random version of all keys in given array (or a specified quantity of them)
Usage
// basic usage
$array = $rand->arrayKeys(array $a);
// usage with all arguments
$array = $rand->arrayKeys(array $a, int $qty = 0);Arguments
| Name | Type(s) | Description |
|---|---|---|
$a | array | Array to get random keys from. |
$qty (optional) | int | Quantity of unique keys to return or 0 for all Default:0 |
Return value
array
API reference based on ProcessWire core version 3.0.257