Skip to content

Instantly share code, notes, and snippets.

@ataylorme
Last active October 12, 2015 22:58
Show Gist options
  • Save ataylorme/4100924 to your computer and use it in GitHub Desktop.
Save ataylorme/4100924 to your computer and use it in GitHub Desktop.
Disallow folder in virtual robots.txt
function virtual_robots_disallow( $output, $public ) {
$output .= "\n" . 'Disallow: /backup' . "\n";
return $output;
}
add_filter( 'robots_txt', 'virtual_robots_disallow', 10, 2 );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment