Files
att-consent/att-consent.php
Steve Hanlon eb35fdabb6 Add TCF v2.2 bridge mode for external CMP integration (v1.3.0)
New cmp_mode setting toggles between the built-in banner (default,
unchanged) and a bridge mode that defers banner UX to an external
IAB TCF v2.2 certified CMP — e.g. Google's free Privacy & messaging
(Funding Choices) or Tarteaucitron.js — and listens to __tcfapi to
keep custom-script gating, attribution preservation, the att_cc_consent
cookie cache and the WP Consent API bridge in sync. Lets sites that
need a Google-certified CMP for EEA/UK AdSense/AdMob serving keep
using this plugin for everything except the consent UI itself.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-06-30 14:10:58 +01:00

32 lines
1.0 KiB
PHP

<?php
/**
* Plugin Name: ATT Consent
* Plugin URI: https://github.com/att-consent/att-consent
* Description: Google Consent Mode v2 cookie consent with session attribution preservation, custom script management, and full gtag.js/GTM support.
* Version: 1.3.0
* Requires at least: 6.0
* Requires PHP: 7.4
* Author: ATT Consent
* Author URI: https://github.com/att-consent
* License: GPL-2.0-or-later
* License URI: https://www.gnu.org/licenses/gpl-2.0.html
* Text Domain: att-consent
* Domain Path: /languages
*/
if ( ! defined( 'ABSPATH' ) ) {
exit;
}
define( 'ATT_CC_VERSION', '1.3.0' );
define( 'ATT_CC_PLUGIN_DIR', plugin_dir_path( __FILE__ ) );
define( 'ATT_CC_PLUGIN_URL', plugin_dir_url( __FILE__ ) );
define( 'ATT_CC_PLUGIN_BASENAME', plugin_basename( __FILE__ ) );
require_once ATT_CC_PLUGIN_DIR . 'includes/class-att-consent.php';
register_activation_hook( __FILE__, array( 'ATT_Consent', 'activate' ) );
register_deactivation_hook( __FILE__, array( 'ATT_Consent', 'deactivate' ) );
ATT_Consent::get_instance();