Skip to content

Instantly share code, notes, and snippets.

@jrxpress
Forked from irazasyed/block-robots.php
Created August 12, 2017 23:56
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jrxpress/1437fc71610e1d8598ceec2b63664cf6 to your computer and use it in GitHub Desktop.
Save jrxpress/1437fc71610e1d8598ceec2b63664cf6 to your computer and use it in GitHub Desktop.
PHP: Block Robots using Headers in PHP.
<?php
@header('X-Robots-Tag: "none, noindex, nofollow, noarchive, nosnippet, noodp, notranslate, noimageindex"');
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment