Created
August 11, 2023 16:41
-
-
Save janboddez/9bcec95c18a50d9de0503f2f6afa5e6c to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
add_filter( 'robots_txt', function( $output, $public ) { | |
$output = str_replace( 'Sitemap:', "User-agent: GPTBot\nDisallow: /\n\nSitemap:", $output ); | |
return $output; | |
}, 10, 2 ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment