Last active
April 25, 2018 20:08
-
-
Save AliceWonderMiscreations/e65bb21f0d6c9c6842f0a535837077ec to your computer and use it in GitHub Desktop.
Basic WP plugin to send RTA (Restricted To Adults) voluntary content label
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 | |
declare(strict_types=1); | |
/** | |
* Plugin Name: AWM RTA Label | |
* Plugin URI: https://gist.github.com/AliceWonderMiscreations/e65bb21f0d6c9c6842f0a535837077ec | |
* Description: Globally enables RTA Label on a WordPress Blog. Enable this plugin, and it is done. Disable plugin to undo. | |
* Version: 2112 | |
* Author: Alice Wonder Miscreations | |
* Author URI: https://github.com/AliceWonderMiscreations/ | |
* License: MIT | |
* Licens URI: https://opensource.org/licenses/MIT | |
* | |
* @package AWonderPHP/RTALabel | |
* @author Alice Wonder <[email protected]> | |
* @license https://opensource.org/licenses/MIT MIT | |
* @link https://gist.github.com/AliceWonderMiscreations/e65bb21f0d6c9c6842f0a535837077ec | |
*/ | |
function awm_rta_header() { | |
header('Rating: RTA-5042-1996-1400-1577-RTA'); | |
} | |
function awm_rta_meta() { | |
echo "<meta name=\"RATING\" content=\"RTA-5042-1996-1400-1577-RTA\" />\n"; | |
} | |
add_action('send_headers', 'awm_rta_header'); | |
add_action('wp_head', 'awm_rta_meta'); | |
?> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment