Dump data from Model

Hey! I’m currently reading and trying out the “Content from a database” Article from the Guide.
I created some virtual pages and now i want to be able to write the content.

Now my question to this. How can i dump and see the data in a page model?

I want to see the content in the writeContent function but i don’t know why.
How can i dump the $data array from writeContent?

class CommentPage extends Kirby\Cms\Page

    public function writeContent(array $data, string $languageCode = null): bool

        if ($comment = Db::first('comments', '*', ['slug' => $this->slug()])) {
            return Db::update('comments', $data, ['slug' => $this->slug()]);
        } else {
            $data['slug'] = $this->slug();
            return Db::insert('comments', $data);


@texnixe . Ok. I put dump($data) in the writeContent method in a page model class. Where would i see the dumped content then?

I figured out that a can use $page->readContent() in a template. So i think i can deal with that.

The data should be shown in a modal in the Panel.

Ok thx. It was my mistake. I write the writeContent method in the wrong class. :see_no_evil: