Problem with reading textarea field content

Hi,

I want to output the content of a textarea field, but it only seems to work if I call my field “text”.

This is the setup that works:

text:
   label: Inhalt
   type: textarea

<?= $page->text()->kirbytext() ?>

But this is what I prefer and it does not work:

content:
   label: Inhalt
   type: textarea

<?= $page->content()->kirbytext() ?>

This also did not work:
<?= $page->text($page->content())->kirbytext() ?>

I’d appreciate any help, thanks!

Content is a native page method, you can use such keys but then have to call them via the content object:

$page->content()->content();
// or
$page->content()->get('content')

Oh, I didn’t know that. Thank you!

https://getkirby.com/docs/guide/content/fields#naming-fields