diff --git a/README.md b/README.md index f8b67cc..5195d18 100644 --- a/README.md +++ b/README.md @@ -2,7 +2,7 @@ Contributors: mnchga Tags: booking, participants, courses, events, eduadmin, lega online, google, analytics, tag manager Requires at least: 5.8 -Tested up to: 6.0 +Tested up to: 6.4 Stable tag: 1.0.0 Requires PHP: 7.0 License: GPL3 @@ -14,3 +14,10 @@ This plugin adds support for Google Analytics / Tag Manager to your EduAdmin plu # EduAdmin - Google Analytics / Tag Manager WordPress This plugin adds support for Google Analytics / Tag Manager to your [EduAdmin-Wordpress plugin](https://github.com/MultinetInteractive/EduAdmin-WordPress). + +The plugin will add javascript to your website that will send events to Google Analytics / Tag Manager when a user interacts with the booking form. + +The domain of the javascript will be from https://www.googletagmanager.com, and you can find their terms of service here: +https://www.google.com/analytics/terms/tag-manager/ + +This plugin requires that you're using the [EduAdmin-Wordpress plugin](https://wordpress.org/plugins/eduadmin-booking/) \ No newline at end of file diff --git a/class/class-edu-google.php b/class/class-edu-google.php index 441b8f2..2ee2d9c 100644 --- a/class/class-edu-google.php +++ b/class/class-edu-google.php @@ -1,8 +1,8 @@ gtag('event', 'view_item_list', { 'item_list_id': 'course_list', 'item_list_name': 'Course list', - 'items': }); + 'items': }); gtag('event', 'view_item_list', { 'item_list_id': 'event_list', 'item_list_name': 'Event list', - 'items': }); + 'items': }); 0 ) { ?> + 'items': }); 0 ) { ?> + 'items': }); 0 ) { ?> + 'items': }); 0 ) { ?> + 'items': }); ', 'value': , 'tax': , - 'items': + 'items': }); . */ -add_action( 'admin_init', 'checkForEduAdminPlugin' ); -function checkForEduAdminPlugin() { - if ( is_admin() && current_user_can( 'activate_plugins' ) && ( ! is_plugin_active( 'eduadmin-booking/eduadmin.php' ) && ! is_plugin_active( 'eduadmin/eduadmin.php' ) ) ) { - add_action( 'admin_notices', function () { - ?> -