Skip to content

Kirby 5.0.4

$layoutColumns->keyOf()

Tries to find the key for the given element

$layoutColumns->keyOf(Kirby\Cms\LayoutColumn $needle): int|string|false

Parameters

Name Type Default Description
$needlerequired Kirby\Cms\LayoutColumn no default value the element to search for

Return types

intorstringorfalse

the name of the key or false

This method modifies the existing $layoutcolumns object it is applied to and returns it again.

Parent class

Kirby\Cms\LayoutColumns inherited from Kirby\Toolkit\Iterator