bobdenotter / seo

Bolt SEO extension
https://bobdenotter.github.io/seo/
MIT License
49 stars 34 forks source link

Set Title and Description for listing page #6

Open dadaxr opened 9 years ago

dadaxr commented 9 years ago

I have a url which looks like : http://mysite.com/blog which is an alias of http://mysite.com/entries ( the content type listing ) and I should be able to set a custom title and description metas for that explicit page.

Maybe add an override array based on the "page" slug in the extension config file ? Or a check on a global twig variable which could be overrided in a template ?

bobdenotter commented 9 years ago

Hi,

I'm assuming you're using listing pages as `/category/movies', right? In this case it is't tied to a specifiv record, and the extension won't know how to create a title and excerpt for it..

How about we add these to the config for the extension:

contenttypes: 
    pages: 
        title: "Title for pages" 
        Description: "Meta description for pages. Meta description for pages. Meta description for pages." 
    entries: 
        title: "Title for entries" 
        Description: "Meta description for entries. Meta description for pages. Meta description for entries." 

Would that work?

dadaxr commented 9 years ago

It should be better indeed.

As for today, i set a twig block with {{ seo.title() }} in the meta, and in an child twig template (used for /category/movies for example ) I override that block content with my own value... does the job but not very clean.

nbehier commented 8 years ago

I did the same as @dadaxr but if anyone have a better way, I'll take it !

dadaxr commented 8 years ago

any news on your elegant proposition @bobdenotter ?

jasperjorna commented 8 years ago

Hey @bobdenotter, any news on this?

otrelin commented 6 years ago

@bobdenotter Are you planning to finish writing this extension for meta title and meta description for the listing pages? It would be nice also meta title and meta description for the taxonomy filtering pages by their values, like this: /taxonomy/optionvalue

GwendolenLynch commented 6 years ago

Help is also welcome :wink: