Skip to content

Kirby 5.1.1

$block->toField()

Converts the block to html first and then places that inside a field object. This can be used further with all available field methods

$block->toField(): Kirby\Content\Field

Return type

Kirby\Content\Field

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

Parent class

Kirby\Cms\Block