• We had an issue with our site being removed from the search engines. At first we thought it was an issue with robots.txt but it turned out to be fine. I also checked Settings > Reading “Discourage search engines from indexing this site” and it was unchecked.

    What we found was this line in our header.php file.

    <meta name=’robots’ content=’noindex,nofollow’ />

    We are wondering if someone would have manually had to put that there or if a malfunctioning plugin could have done it?

Viewing 7 replies - 1 through 7 (of 7 total)
  • It’s most likely from a theme option (as opposed to a general WP setting).

    Check your theme options, and if not that, please ask the theme provider.

    You could comment the line out by changing it like this:

    <!---<meta name='robots' content='noindex,nofollow' />--->

    https://www.w3schools.com/html/html_comments.asp

    Note that if this edit is made within a parent theme, the edit may be lost on theme update.

    Thread Starter saleaway

    (@saleaway)

    I already deleted the line, just trying to figure out how it got there as it destroyed our rankings in about 1 week. I’ve submitted site maps using web master tools but rankings are very slow to appear in google. It was difficult to detect because google webmaster tools only looks at the robots.txt file and give the green thumb.

    Thread Starter saleaway

    (@saleaway)

    I did check theme options and didn’t see anything that would of caused it. It’s a custom theme so it won’t be getting updates.

    Mahesh

    (@sparxengine)

    Theme or plugin options often do that too. So check if there is any SEO plugin or the Theme option set to that option.

    Plugins should not actually edit the theme’s header.php file, but that is if they are following the rules, so if it was a plugin, it was not one I would advise the use of. As for SEO plugins, they (should) use functions to include the meta tags within the head (as output).

    So, an errant plugin or a manual edit is my best guess (or it simply was there and was never noticed?)

    Thread Starter saleaway

    (@saleaway)

    I have yoast but checked all the settings and I don’t think it would actually edit the header.php file. The site was being worked on by a developer who also wanted to sell us an seo package so we think they probably had something to do with it. There were also a bunch of plugins that were added \ removed during the time. We have a copy of the original site and the robots meta tags were not there until making the developers changes live.

    In PHP it’s like this:

    if ($contact = $SEO_SALESMAN) {
    function (RUN LIKE HELL);
    }

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘robots meta tags on header.php’ is closed to new replies.