news icon indicating copy to clipboard operation
news copied to clipboard

Control (no)index and (no)follow of each news

Open t3easy opened this issue 3 years ago • 6 comments

Feature Request

Is your feature request related to a problem? Please describe. If i set the index this site switch of a news detail page to noindex, it gets removed from the core seo sitemap but all news also habe noindex in the head. If i set it to index, the detail page is in the pages sitemap without any news to display and ext:news sends 404 header because no news is given. Google search console is unhappy because I send pages that send 404.

Describe the solution you'd like I want to remove the detail page without a displayed news from the sitemap and set it to noindex but let search engine index the news. Therefore each news should have (no)index and (no)follow settings that overrules the page settings.

t3easy avatar Jun 14 '21 08:06 t3easy

You could leave no_index = 0 and add this to the sitemap config:

            pages {
                config {
                    additionalWhere := appendString( AND uid != 54)
                }
            }

But I would also like to see no_index in the seo tab of news because there are some news that are not worth to get indexed because they are only temporary like 'new year greatings'. In this case the no_index meta would be useful.

ste101 avatar Jun 29 '21 19:06 ste101

I do it like this

  • Set no_index on detail pages
  • Use in pages sitemap additionalWhere = AND no_index=0

This way, detail pages are not in the sitemap. And then activate index,follow for the news detail view

[traverse(request.getQueryParams(), 'tx_news_pi1/news') > 0]
    page.meta.robots = TEXT
    page.meta.robots {
        value = index,follow
        replace = 1
    }
[global]

Would you like add it in the documentation if it fits your needs?

christophlehmann avatar Jul 15 '21 20:07 christophlehmann

Would you like add it in the documentation if it fits your needs?

You can find this already here: https://docs.typo3.org/p/georgringer/news/8.5/en-us/AdministratorManual/BestPractice/Seo/Index.html#robots-allow-indexing-of-news-records-but-set-noindex-to-the-detail-page

ste101 avatar Jul 15 '21 21:07 ste101

Great. We don't to add it ;)

christophlehmann avatar Jul 15 '21 21:07 christophlehmann

@t3easy should we close the issue?

georgringer avatar Jul 27 '21 16:07 georgringer

I would leave it open to implement a per news (no)index and (no)follow setting.

t3easy avatar Jul 27 '21 16:07 t3easy

I am closing this issue as I don't plan to implement it.

if someone needs it, feel free to sponsor it and contact me in private

georgringer avatar Aug 23 '22 18:08 georgringer