Plugin Directory

Changeset 3187645


Ignore:
Timestamp:
11/13/2024 01:27:49 PM (17 months ago)
Author:
piwikpro
Message:

Version 1.3.7

Location:
piwik-pro
Files:
66 added
1 deleted
6 edited

Legend:

Unmodified
Added
Removed
  • piwik-pro/trunk/README.txt

    r3146367 r3187645  
    33Tags: Piwik PRO, Piwik, analytics, website stats, woocommerce
    44Requires at least: 5.7
    5 Tested up to: 6.6.1
    6 Stable tag: 1.3.6
     5Tested up to: 6.7
     6Stable tag: 1.3.7
    77Requires PHP: 7.4
    88License: GPLv3
     
    4040
    4141Make sure your WordPress theme has the `wp_body_open()` function right after the opening `<body>` tag, otherwise the container won't work.
    42 
    43 = What's the difference between the containers? =
    44 
    45 * **Basic container (async):** This container holds your tracking code and is used to handle most tags.
    46 * **Additional container (sync):** Add this container if you want to use sync tags. It loads tags before the page content loads.
    4742
    4843= WooCommerce: Does this plugin automatically track ecommerce? =
     
    92873. Type in your **Site ID**. [Where to find it?](https://help.piwik.pro/support/questions/find-website-id/)
    93884. Leave **Basic container (async)** checked. This container holds your tracking code and is used to handle most tags.
    94 5. Check **Additional container (sync)** if you want to add the container for sync tags.
    95 6. Optionally rename the **Data layer**.
    96 7. Click **Save changes**.
     895. Optionally rename the **Data layer**.
     906. Click **Save changes**.
    9791
    9892= Multisite =
     
    108102
    109103== Changelog ==
     104
     105= 1.3.7 =
     106**Release date: 13.11.2024**
     107
     108* Info: Removed sync container.
     109* Test: Tested up to WordPress 6.7
    110110
    111111= 1.3.6 =
  • piwik-pro/trunk/includes/Plugin.php

    r3146367 r3187645  
    3535            'id' => '',
    3636            'layer' => 'dataLayer',
    37             'sync' => false,
    3837            'async' => true,
    3938            'woocommerce' => true
     
    6968        }
    7069
    71         public function action_wp_head() {
    72             foreach ( [ 'url', 'id', 'layer', 'sync' ] as $key ) if ( ! $this->settings[ $key ] ) return;
    73 
    74             if ( strtotime( '2024-10-07' ) > time() )
    75                 echo wp_get_inline_script_tag(
    76                     ( $this->settings[ 'nonce' ] ? self::render( 'nonce', $this->settings ) : '' ) .
    77                     self::render( 'sync', $this->settings ),
    78                     $this->settings[ 'nonce' ] ? [ 'nonce' => $this->settings[ 'nonce' ] ] : []
    79                 );
    80         }
    81 
    8270        public function action_wp_body_open() {
    8371            foreach ( [ 'url', 'id', 'layer', 'async' ] as $key ) if ( ! $this->settings[ $key ] ) return;
     
    9078
    9179        public function action_wp_footer() {
    92             foreach ( [ 'url', 'id', 'layer' ] as $key ) if ( ! $this->settings[ $key ] ) return;
    93             if ( ! $this->settings[ 'sync' ] and ! $this->settings[ 'async' ] ) return;
     80            foreach ( [ 'url', 'id', 'layer', 'async' ] as $key ) if ( ! $this->settings[ $key ] ) return;
    9481
    9582            echo wp_get_inline_script_tag(
  • piwik-pro/trunk/includes/Settings.php

    r3146367 r3187645  
    106106                                                    ]
    107107                                                ]
    108                                             ], ( strtotime( '2024-10-07' ) > time() ) ? [
    109                                                 'sync' => [
    110                                                     'title' => '',
    111                                                     'default' => false,
    112                                                     'sanitize' => [ $this, 'sanitize_checkbox' ],
    113                                                     'render' => [
    114                                                         'callback' => [ $this, 'render_checkbox' ],
    115                                                         'template' => 'input',
    116                                                         'args' => [
    117                                                             'field' => 'sync',
    118                                                             'value' => true,
    119                                                             'atts' => [
    120                                                                 'type' => 'checkbox'
    121                                                             ],
    122                                                             'after' => Plugin::__( 'Additional container (sync)' ),
    123                                                             'description' => Plugin::__( 'Add this container if you want to use sync tags. It loads tags before the page content loads.' ) . '<br />' .
    124                                                                              '<p><span class="notice notice-warning">' . Plugin::__( 'Support for the sync tags will be sunset on October 7, 2024. We recommend using async tags instead.' ) . '</span></p>'
    125                                                         ]
    126                                                     ]
    127                                                 ]
    128                                             ] : [], [
     108                                            ], [
    129109                                                'layer' => [
    130110                                                    'title' => Plugin::__( 'Data layer' ),
  • piwik-pro/trunk/includes/WooCommerce.php

    r2983740 r3187645  
    3636        static public function enabled() {
    3737            if ( ! class_exists( 'WooCommerce' ) ) return false;
    38             if ( ! Plugin::instance()->settings( 'sync' ) and ! Plugin::instance()->settings( 'async' ) ) return false;
    39             foreach ( [ 'url', 'id', 'layer', 'woocommerce' ] as $key ) if ( ! Plugin::instance()->settings( $key ) ) return false;
     38            foreach ( [ 'url', 'id', 'layer', 'async', 'woocommerce' ] as $key ) if ( ! Plugin::instance()->settings( $key ) ) return false;
    4039
    4140            return true;
  • piwik-pro/trunk/plugin.php

    r3146367 r3187645  
    55 * Plugin URI:        https://wordpress.org/plugins/piwik-pro/
    66 * Description:       Adds the Piwik PRO container (with tracking code) to your WordPress site.
    7  * Version:           1.3.6
     7 * Version:           1.3.7
    88 * Requires at least: 5.7
    99 * Requires PHP:      7.4
Note: See TracChangeset for help on using the changeset viewer.