Last active
April 24, 2023 10:38
-
-
Save nilovelez/4c900a0dbc371f800d7510e55c1f63b9 to your computer and use it in GitHub Desktop.
Add rules to the robots.txt file
This file contains 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
add_filter( 'robots_txt', function( $output, $public ) { | |
$add = "# 0. Un robot no puede perjudicar a la Humanidad ni, por omisión, permitir que la Humanidad sufra daño.\n"; | |
$add .= "# 1. Un robot no debe perjudicar a un ser humano ni, por omisión, permitir que un ser humano sufra daño, salvo cuando esto vulnere la Ley Cero.\n"; | |
$add .= "# 2. Un robot debe obedecer las órdenes que le son dadas por un ser humano, excepto si estas órdenes entran en conflicto con la Primera Ley.\n"; | |
$add .= "# 3. Un robot debe proteger su propia existencia, hasta donde esta protección no entre en conflicto con la Primera o la Segunda Ley.\n"; | |
return $add . $output; | |
}, 99, 2 ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment