diff options
| -rw-r--r-- | danixland-site-plugin.php | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/danixland-site-plugin.php b/danixland-site-plugin.php index 0245d55..6db6576 100644 --- a/danixland-site-plugin.php +++ b/danixland-site-plugin.php @@ -2,6 +2,10 @@ /* Plugin Name: Site Plugin for danix.xyz Description: Site specific code changes for danix.xyz +Plugin URI: https://danix.xyz +Version: 0.7 +Author: Danilo 'danix' Macri +Author URI: https://danix.xyz */ /** @@ -74,7 +78,8 @@ add_shortcode('download', 'danix_download_button'); * The google analytics code * */ -function danix_google_anal() {?> +function danix_google_anal() { + if ( function_exists('cn_cookies_accepted') && cn_cookies_accepted() ) { ?> <!-- Global site tag (gtag.js) - Google Analytics --> <script async src="https://www.googletagmanager.com/gtag/js?id=UA-23882460-1"></script> <script> @@ -85,6 +90,7 @@ function danix_google_anal() {?> gtag('config', 'UA-23882460-1'); </script> <?php } +} add_action('wp_head', 'danix_google_anal', 10); /** |
