Skip to content

Kirby 5.0.4

$fieldClass->indexOf()

Returns the position / index in the collection

$fieldClass->indexOf(Kirby\Form\Fields|null $collection = null): int|false

Parameters

Name Type Default
$collection Kirby\Form\Fieldsornull null

Return types

intorfalse

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

Parent class

Kirby\Form\FieldClass