vaersaagod / seomate

SEO, mate! It's important. That's why SEOMate provides the tools you need to craft all the meta tags, sitemaps and JSON-LD microdata you need - in one highly configurable, open and friendly package - with a super-light footprint.
MIT License
36 stars 8 forks source link

Fix canonical url on paginated content #44

Closed rbrv closed 4 years ago

rbrv commented 4 years ago

Craft supports pagination of content with a specific page trigger.

At the moment, no matter what page a visitor is on, the SeoMate-generated canonical url points to the first page. SEO best practices dictate it should point to the paginated URL.

Reference article: https://www.searchenginejournal.com/technical-seo/pagination/

How it is now

How it should be

mmikkel commented 4 years ago

I'm able to reproduce.

This only happens if there's an element matched for the current route – for example if you're using {% paginate %} in a template that's set as the entry template for a section (in which case there's going to be an entry matched for the request, and SEOMate will output that entry's URL for the canonical, and disregard the pagination trigger in the current request URL).

I agree that this is a bug though – will get it fixed.

aelvan commented 4 years ago

This was fixed in 1.1.5.

architchandra commented 3 years ago

I'm still facing this issue. Will try to set the canonical URL manually instead. But it would be great of this can be fixed within the plugin itself.

SEOMate: 1.1.7 Craft: 3.4.30