Skip to content

Kirby 3.5.7.1

A::nestByKeys()

Recursively creates a nested array from a set of keys with a key on each level

A::nestByKeys(mixed $value, array $keys): array|mixed

Parameters

Name Type Default Description
$value * mixed Arbitrary value that will end up at the bottom of the tree
$keys * array List of keys to use sorted from the topmost level

Return type

array|mixed

Parent class

Kirby\Toolkit\A