fabianmichael / kirby-meta

All-in-one solution to all of your SEO/OpenGraph/JSON-LD needs. 👀
MIT License
65 stars 8 forks source link

Overwrite page titel via model #37

Open jonasfeige opened 1 year ago

jonasfeige commented 1 year ago

Hey, really great plugin!

Is it possible to overwrite the page's <title> via its model? If I read the docs correctly, I can only add additional metadata but not overwrite anything, is that correct?

fabianmichael commented 1 year ago

@jonasfeige No, that’s currently not possible for the title field. What exactly do you want to do with that?

jonasfeige commented 1 year ago

I have a client who offers different classes, and each of the corresponding dates has a unique page. The template has auto-generated, randomized titles, because they are only used internally. Ideally, I would be able to overwrite the title and e.g. use the title of the page's parent.

fabianmichael commented 1 year ago

Okay, so do you think it’s necessary to override the whole title or just the part before the separator? Providing one from the model sounds like a good idea, it can still be overridden by hand if necessary.

jonasfeige commented 1 year ago

For my use case the page title (before the separator) would be enough. And yeah, customizability via the model with even more control via the panel would be amazing!

fabianmichael commented 1 year ago

@jonasfeige I’m happy to add this feature since it might be interesting to many other users. Unfortunately I don’t know when I will have the time for doing that.