Get content from one page to appear on all pages

I understand how to display a pages content on a page, using the $page variable, and site content on a page using the $site variable (Templates | Kirby CMS)

But how do I get content from one page (the homepage) to be added to several pages?

I currently have:
<meta property="og:description" content="<?= $page->description_meta_tag() ?>" />

but want it to be something like
<meta property="og:description" content="<?= $home->description_meta_tag() ?>" />

That doesn’t work. And neither does this:

<meta property="og:description" content="<?= $page->find('home')->description_meta_tag() ?>" />

These don’t work either
<meta property="og:description" content="<?= $page('home')->description_meta_tag() ?>" />

<meta property="og:description" content="<?= $page('index')->description_meta_tag() ?>" />

Is this possible?

Okay, this works. It seems there is a difference between page and pages

<meta property="og:description" content="<?= $pages->find('home')->description_meta_tag() ?>" />

An alternative would be to use the page helper:

if ($p = page('home')) {
  echo $p->title();
}

Note that you are usually better off if you make sure the desired page/file/whatever exists, before calling any member methods (like in the example).

If the object does not exist, you will get the famous calling xyz() on null error…

Right, got you, I simply thought if content didn’t exist, it simply wouldn’t display – rather than break the whole page.

Thanks for the tip about the page helper.

If you want to understand why it is the way it is, read this: A brief intro to object oriented programming in PHP | Kirby CMS