Changeset 2742250
- Timestamp:
- 06/14/2022 12:42:06 PM (4 years ago)
- Location:
- vine-ma/trunk
- Files:
-
- 2 edited
-
readme.txt (modified) (1 diff)
-
vine_ma_plugin.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
vine-ma/trunk/readme.txt
r2682304 r2742250 21 21 22 22 == Changelog == 23 24 = 1.1.4 = 25 * Internal changes 23 26 24 27 = 1.1.3 = -
vine-ma/trunk/vine_ma_plugin.php
r2466774 r2742250 3 3 /** 4 4 * Plugin Name: Vine MA - Email Marketing, Forms, Interactive Bot Forms, Chatbot, Analytics 5 * Version: 1.1. 35 * Version: 1.1.4 6 6 * Description: Vine is a Marketing automation tool to generate more leads from your web site. Vine includes web forms, interactive bot forms, landing pages, AI chatbot, visitor tracking, and other functionality to help you to make your site more interesting and to know better what your visitors do there. 7 7 * Author: Vine Oy … … 90 90 $orgid = vine_ma_get_option('organization_id'); 91 91 $src = VINEHOST."/track/t.js?sg={$orgid}"; 92 wp_enqueue_script('vinematrack', $src, array(), null); 93 } 92 wp_enqueue_script('vinematrack', $src, array(), null); 93 wp_script_add_data('vinematrack', 'main-track-script', true ); 94 $srcac = VINEHOST."/track/allowCookies.js"; 95 wp_enqueue_script('vinematrackac', $srcac, array(), null); 96 wp_script_add_data('vinematrackac', 'ac-track-script', true ); 97 } 98 function vine_track_scripts_attributes( $tag, $handle ) { 99 if ( wp_scripts()->get_data( $handle, 'main-track-script' ) ) { 100 $tag = str_replace( '></', ' data-cookieconsent="ignore"></', $tag ); 101 $tag = str_replace( '<script', '<script type="text/javascript"', $tag ); 102 } 103 if ( wp_scripts()->get_data( $handle, 'ac-track-script' ) ) { 104 $tag = str_replace( '></', ' data-cookieconsent="marketing" async></', $tag ); 105 $tag = str_replace( '<script', '<script type="text/plain"', $tag ); 106 } 107 return $tag; 108 } 94 109 add_action( 'wp_enqueue_scripts', 'vine_ma_wpes_hook_add_script'); 110 add_filter( 'script_loader_tag', 'vine_track_scripts_attributes', 10, 2 ); 95 111 96 112 add_action( 'wp_ajax_vine_ma_save_option', 'vine_ma_hook_save_option' );
Note: See TracChangeset
for help on using the changeset viewer.