Embedding metadata into collections / channels and the (Page 1) problem

Wanted to summarize a problem I had and ask for feedback:

I use the world-famous Krabi theme. When I created multiple collections in routes.yaml, I noticed that the browser tab displayed title as Site Title (Page 1)…I read up on this and found a solution (creating separate template for each collection and applying custom titles)

But the mystery remains: where does (Page 1) come from?

My head.hbs defines title like this:

{{ meta_title }}

And is there no better way for embedding metadata into collections / channels, than to create separate template for each?

The other solution I read is to create static pages and then assigning them to each collection / channel through a Data: attribute in routes.yaml …but that creates random pages on your website, which Google will probably index.

Is your site public … just curious to see Krabi in action in the way you describe.

1 Like

Thanks for asking, I’ll DM you the password…would appreciate anyone who wants to test it…I took Krabi, eliminated sidebars to provide more focus, then changed the tags list to feature a mega menu with all the main tags

If you create static pages with the same name/slug as your collection they wont render or be separately visible, will they?

1 Like

Great point, I had not thought of that…that makes both solutions equally elegant…which would you favor, I just want to get basic metadata in?

Eeh I actually don’t know, I’m unsure. Maybe someone else has an opinion?

I used to mess around with this a lot with earlier versions of ghost, it was quite an issue. I was trying to do code insert also with schema data, and have it show up on collection pages. Hopefully it’s sorted out now.

I remember being confused also with what was actually rendered as meta - the stuff I put in metada flields or the description field, I had the impression the developers were switching back and forth with different ghost versions. I might be wrong though.

Would be interesting if you let us know if you made it work, metadata rendering the way it should?

1 Like

Yes, with Ghost 3.4x, as far as the title is concerned, both the static page method and the custom template method work well (don’t quite know if the meta description is rendering as well)…maybe @DavidDarnes and @marekgregor could help us with the latest on this issue (they were the ones who suggested the solutions to embed metadata into a custom collection)

You might benefit from this solution I gave in another topic:

1 Like

yes, thanks, have already benefited, that’s the approach I am using

1 Like