ExpressionEngine CMS
Open, Free, Amazing

Thread

This is an archived forum and the content is probably no longer relevant, but is provided here for posterity.

The active forums are here.

How do I stop Google indexing Single Entry template

July 04, 2008 8:36am

Subscribe [4]
  • #1 / Jul 04, 2008 8:36am

    Kim Agnew

    7 posts

    Hi,

    Hopefully there is an easy answer for this, and I am just having a ‘can’t see the wood for the trees’ moment.

    I have the standard blog section. /blog/index is listing the summaries of recent posts, with a permalink of blog/article leading to the single entry page showing the full article.

    Google is indexing the single full article with the correct url of blog/article/some-post, but is also indexing the blog/article page with all articles showing in full.

    How do I stop Google indexing the blog/article page, without preventing it from indexing blog/article/some-post as well?

    thanks

    Kim

  • #2 / Jul 04, 2008 8:38am

    Danny T.

    426 posts

    Kim,

    I’m not really sure what you would want to do. But I have an idea of what might be able to help you. There is a parameter called “require_entry” you can use in your {exp:weblog:entries} tag that does exactly what it says. It requires it to be linked through to in order to produce a look. Here’s the link to the ExpressionEngine Documentation in regards to its usage.

    With that in mind, you can run a conditional that can either display a list of your articles, or produce an error message on the page for clarity sake.

    I’m not really sure what kind of repercussion’s you’d have on adding the page to robots.txt, but I’d probably go with the above route if I were in your situation (which I probably will be sooner or later).

  • #3 / Jul 04, 2008 8:42am

    Ingmar

    29245 posts

    I don’t know, something like this, perhaps?

    {if segment_3 == ""}
    <meta name="googlebot" content="follow,noindex,noarchive" />
    {/if}
  • #4 / Jul 04, 2008 8:44am

    Danny T.

    426 posts

    I think Ingmar trumped me on this one. God bless the forums for better knowledge!

  • #5 / Jul 04, 2008 9:01am

    Kim Agnew

    7 posts

    *doh* I knew I should have gotten round to looking up segments in the user guide sooner. 😊

    thanks!

  • #6 / Jul 04, 2008 9:03am

    Andy Harris

    958 posts

    You might want to block all bots rather than just Google too.

.(JavaScript must be enabled to view this email address)

ExpressionEngine News!

#eecms, #events, #releases