Dynamic data from database on google side

I am quite new in programming. I am here today to ask a question about dynamic data on the website. I want to create a website whose content will be managed by CMS which I will create. In the CMS settings, I want to be able to set up data such as TITLE, DESCRIPTION, LOGO PATH for the site. This data will be stored in the database. How will it all work on the google side? The informations/data are dynamic and will be downloaded only if someone enters my website, and what if someone in the search engine enter the title of my page? Title, description, will they be visible in the results ? I use Cakephp 3.7 and php 7.3.3.

Thanks for any answers

Hii there,

how do you mean “on the google side”?
If you mean how it’ll look on search engines like Google and DuckDuckGo, then use the “og:description” meta in your template.
Unfortunately, CakePHP has no real built-in way so I just hack it by doing this:

<?= $this->Html->meta(
  'This is my awesome new site baked with cake', // This can also be a variable, of course
  ['property' => "og:description"]
); ?>

It’ll show up in the HTML as:

<meta property="og:description" content="This is my awesome new site baked with cake"/>

And on DuckDuckGo it should render (on Google too but I don’t use that) as:

Do note that the screenshot is made using element inspector for demo purposes :slight_smile:

Search engines used to use the description meta but this has changed to the Open Graph protocol as far as I can tell.