Plugin Directory

Changeset 2483655


Ignore:
Timestamp:
03/01/2021 04:00:40 PM (5 years ago)
Author:
quentn
Message:

Improve the method of how cookie value is fetched to check page access permission

Location:
quentn-wp/trunk
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • quentn-wp/trunk/includes/class-quentn-wp-restrict-access.php

    r2371136 r2483655  
    282282        //get already saved cookie value if dont find in url
    283283        if( empty( $get_access_emails ) ) {
    284 
    285284            $cookie_saved_data = $this->get_json_cookie( 'qntn_wp_access' );
    286 
    287             $get_access_emails = ( isset( $cookie_saved_data['access'][get_the_ID()] ) ) ?  $cookie_saved_data['access'][get_the_ID()] : array();
     285            //get access emails of all pages from cookie
     286            $get_all_access_emails = ( isset( $cookie_saved_data['access'] ) ) ?  $cookie_saved_data['access'] : array();
     287            if ( ! empty( $get_all_access_emails ) ) {
     288                foreach ( $get_all_access_emails as $get_access_page_emails ) { //loop through all access for each page
     289                    foreach ( $get_access_page_emails as $get_access_page_email ) { //each page can have multiple access emails, add all of them
     290                        $get_access_emails[] = $get_access_page_email;
     291                    }
     292                }
     293            }
    288294        }
    289295        return $get_access_emails;
  • quentn-wp/trunk/includes/class-quentn-wp.php

    r2441489 r2483655  
    7575            $this->version = QUENTN_WP_VERSION;
    7676        } else {
    77             $this->version = '1.1.4';
     77            $this->version = '1.1.5';
    7878        }
    7979        $this->plugin_name = 'quentn-wp';
  • quentn-wp/trunk/quentn-wp.php

    r2441489 r2483655  
    1717 * Plugin URI:        https://docs.quentn.com/de/beta-quentn-wordpress-plugin/installieren-und-verbinden
    1818 * Description:       This plugin allows you to restrict access to specific pages, create custom access links and create dynamic page countdowns. Optionally, you can connect your Quentn account to your WordPress installation to share contacts and manage access restrictions through Quentn.
    19  * Version:           1.1.4
     19 * Version:           1.1.5
    2020 * Author:            Quentn.com GmbH
    2121 * Author URI:        https://quentn.com/
     
    3535define( "TABLE_QUENTN_RESTRICTIONS", 'qntn_restrictions' );
    3636define( "TABLE_QUENTN_USER_DATA", 'qntn_user_data' );
    37 define( 'QUENTN_WP_VERSION', '1.1.4' );
     37define( 'QUENTN_WP_VERSION', '1.1.5' );
    3838
    3939/**
  • quentn-wp/trunk/readme.txt

    r2441489 r2483655  
    44Requires at least: 4.6.0
    55Tested up to: 5.6
    6 Stable tag: 1.1.4
     6Stable tag: 1.1.5
    77Requires PHP: 5.6.0
    88License: GPLv2 or later
     
    6666
    6767== Changelog ==
     68= 1.1.5 =
     69* Improve the method of how cookie value is fetched to check page access permission.
     70
    6871= 1.1.4 =
    6972* Fix: Elementor integration for WordPress version 5.6.
     
    119122== Upgrade Notice ==
    120123
     124= 1.1.5 =
     125Thanks for using Quentn Plugin! Please update the plugin to improve handling of page access permission.
     126
    121127= 1.1.4 =
    122128Thanks for using Quentn Plugin! Please update the plugin to fix elementor integration for WordPress version 5.6.
Note: See TracChangeset for help on using the changeset viewer.