Plugin Directory

Changeset 3242177


Ignore:
Timestamp:
02/17/2025 08:39:46 PM (13 months ago)
Author:
roundupwp
Message:
  • Fix: Fixed PHP warning Undefined property: RTEC_Form:: when using the log-in form for logged-out visitors when the event is for logged-in users only.
Location:
registrations-for-the-events-calendar
Files:
143 added
3 edited

Legend:

Unmodified
Added
Removed
  • registrations-for-the-events-calendar/trunk/inc/form/class-rtec-form.php

    r3183954 r3242177  
    15471547            $args  = array(
    15481548                'echo'     => false,
    1549                 'redirect' => get_the_permalink( $this->event_id ),
     1549                'redirect' => get_the_permalink( $this->event_meta['event_id'] ),
    15501550            );
    15511551            $html .= '<div class="rtec-event-meta"><div class="rtec-login-wrap">' . wp_login_form( $args ) . '</div></div>';
  • registrations-for-the-events-calendar/trunk/readme.txt

    r3223149 r3242177  
    77Tested up to: 6.7
    88Requires PHP: 7.4
    9 Stable tag: 2.13.3
     9Stable tag: 2.13.4
    1010License: GPLv2 or later
    1111License URI: http://www.gnu.org/licenses/gpl-2.0.html
     
    202202
    203203== Changelog ==
     204= 2.13.4 =
     205* Fix: Fixed PHP warning "Undefined property: RTEC_Form::$event_id" when using the log-in form for logged-out visitors when the event is for logged-in users only.
     206
    204207= 2.13.3 =
    205208* Fix: When a logged-in user canceled a registration, there would be no email confirmation or email notification.
  • registrations-for-the-events-calendar/trunk/registrations-for-the-events-calendar.php

    r3223149 r3242177  
    33Plugin Name: Registrations for The Events Calendar
    44Description: Collect and manage event registrations with a customizable form and email template. This plugin requires The Events Calendar by Modern Tribe to work.
    5 Version: 2.13.3
     5Version: 2.13.4
    66Author: Roundup WP
    77Author URI: roundupwp.com
     
    3838// Plugin version.
    3939if ( ! defined( 'RTEC_VERSION' ) ) {
    40     define( 'RTEC_VERSION', '2.13.3' );
     40    define( 'RTEC_VERSION', '2.13.4' );
    4141}
    4242// Plugin Folder Path.
     
    5050
    5151if ( ! defined( 'RTEC_TEC_VER_STRING' ) ) {
    52     define( 'RTEC_TEC_VER_STRING', '.6.8.3' );
     52    define( 'RTEC_TEC_VER_STRING', '.6.10.1' );
    5353}
    5454
     
    257257        public static function activation_scripts( $network_wide ) {
    258258            if ( is_multisite() && $network_wide && function_exists( 'get_sites' ) && class_exists( 'WP_Site_Query' ) ) {
    259 
    260259                // Get all blogs in the network and activate plugin on each one
    261260                $sites = get_sites();
    262261                foreach ( $sites as $site ) {
    263262                    switch_to_blog( $site->blog_id );
    264 
    265263                    self::install();
    266 
    267264                    restore_current_blog();
    268265                }
     
    270267                self::install();
    271268            }
     269           
     270            // Set transient for redirect
     271            set_transient( 'rtec_activation_redirect', true, 30 );
    272272        }
    273273
     
    313313            update_user_meta( get_current_user_id(), 'tribe-dismiss-notice-time-event-tickets-install', '1823773858' );
    314314            update_user_meta( get_current_user_id(), 'tribe-dismiss-notice', 'event-tickets-install' );
     315            update_option( 'tec_events_onboarding_page_dismissed', true );
    315316        }
    316317    }
     
    350351}
    351352add_filter( 'wpmu_drop_tables', 'rtec_on_delete_blog' );
     353
     354function rtec_activation_redirect() {
     355    // Check if we should redirect
     356    if ( get_transient( 'rtec_activation_redirect' ) ) {
     357        // Delete the transient
     358        delete_transient( 'rtec_activation_redirect' );
     359       
     360        // Only redirect if we're on the main plugin page
     361        if ( ! isset( $_GET['activate-multi'] ) && ! is_network_admin() ) {
     362            // Safe redirect to the main plugin page
     363            wp_safe_redirect( admin_url( 'admin.php?page=registrations-for-the-events-calendar' ) );
     364            exit;
     365        }
     366    }
     367}
     368add_action( 'admin_init', 'rtec_activation_redirect' );
    352369
    353370/**
Note: See TracChangeset for help on using the changeset viewer.