Skip to content

Kirby 5.0.4

$api->fieldApi()

$api->fieldApi(Kirby\Cms\ModelWithContent $model, string $name, string|null $path = null): mixed

Parameters

Name Type Default
$modelrequired Kirby\Cms\ModelWithContent no default value
$namerequired string no default value
$path stringornull null

Return type

mixed

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

Exceptions

Type Description
Kirby\Exception\NotFoundException if the field type cannot be found or the field cannot be loaded

Parent class

Kirby\Cms\Api