WordPress.org

Plugin Directory

Changeset 1677796


Ignore:
Timestamp:
06/13/17 16:55:01 (2 months ago)
Author:
netweblogic
Message:

updating to 5.7.3

Location:
events-manager/trunk
Files:
10 edited

Legend:

Unmodified
Added
Removed
  • events-manager/trunk/admin/em-bookings.php

    r1651260 r1677796  
    473473                                <input type="hidden" name="action" value="bookings_add_note" /> 
    474474                                <input type="hidden" name="_wpnonce" value="<?php echo wp_create_nonce('bookings_add_note'); ?>" /> 
    475                                 <input type="submit" class="em-button button-primary" value="Add Note" /> 
     475                                <input type="submit" class="em-button button-primary" value="<?php esc_html_e('Add Note', 'events-manager'); ?>" /> 
    476476                            </form> 
    477477                        </div> 
  • events-manager/trunk/admin/em-ms-options.php

    r1657983 r1677796  
    6767     
    6868    global $save_button; 
    69     $save_button = '<tr><th>&nbsp;</th><td><p class="submit" style="margin:0px; padding:0px; text-align:right;"><input type="submit" id="dbem_options_submit" name="Submit" value="'. __( 'Save Changes', 'events-manager') .' ('. __('All','events-manager') .')" /></p></ts></td></tr>'; 
     69    $save_button = '<tr><th>&nbsp;</th><td><p class="submit" style="margin:0px; padding:0px; text-align:right;"><input type="submit" class="button-primary" name="Submit" value="'. __( 'Save Changes', 'events-manager') .' ('. __('All','events-manager') .')" /></p></td></tr>'; 
    7070    //Do some multisite checking here for reuse 
    7171    ?>   
     
    190190 
    191191            <p class="submit"> 
    192                 <input type="submit" id="dbem_options_submit" name="Submit" value="<?php esc_attr_e( 'Save Changes' )?>" /> 
     192                <input type="submit" class="button-primary" name="Submit" value="<?php esc_attr_e( 'Save Changes', 'events-manager'); ?>" /> 
    193193                <input type="hidden" name="em-submitted" value="1" /> 
    194194                <input type="hidden" name="_wpnonce" value="<?php echo wp_create_nonce('events-manager-options'); ?>" /> 
  • events-manager/trunk/admin/em-options.php

    r1658866 r1677796  
    227227        echo json_encode($options); 
    228228        exit(); 
    229     } 
    230     if( !empty($_REQUEST['action']) && $_REQUEST['action'] == 'export_ms_em_settings' && check_admin_referer('export_ms_em_settings') && is_multisite() && is_super_admin() ){ 
     229    }elseif( !empty($_REQUEST['action']) && $_REQUEST['action'] == 'export_em_ms_settings' && check_admin_referer('export_em_ms_settings') && is_multisite() && is_super_admin() ){ 
    231230        //delete transients, and add a flag to recheck dev version next time round 
    232231        global $EM_MS_Globals, $wpdb; 
     
    347346     
    348347    global $save_button; 
    349     $save_button = '<tr><th>&nbsp;</th><td><p class="submit" style="margin:0px; padding:0px; text-align:right;"><input type="submit" class="button-primary" id="dbem_options_submit" name="Submit" value="'. __( 'Save Changes', 'events-manager') .' ('. __('All','events-manager') .')" /></p></ts></td></tr>'; 
     348    $save_button = '<tr><th>&nbsp;</th><td><p class="submit" style="margin:0px; padding:0px; text-align:right;"><input type="submit" class="button-primary" name="Submit" value="'. __( 'Save Changes', 'events-manager') .' ('. __('All','events-manager') .')" /></p></td></tr>'; 
    350349     
    351350    if( defined('EM_SETTINGS_TABS') && EM_SETTINGS_TABS ){ 
     
    417416 
    418417            <p class="submit"> 
    419                 <input type="submit" id="dbem_options_submit" class="button-primary" name="Submit" value="<?php esc_attr_e( 'Save Changes', 'events-manager'); ?>" /> 
     418                <input type="submit" class="button-primary" name="Submit" value="<?php esc_attr_e( 'Save Changes', 'events-manager'); ?>" /> 
    420419                <input type="hidden" name="em-submitted" value="1" /> 
    421420                <input type="hidden" name="_wpnonce" value="<?php echo wp_create_nonce('events-manager-options'); ?>" /> 
  • events-manager/trunk/classes/em-categories-taxonomy.php

    r1651260 r1677796  
    4040    public static function form($tag){  
    4141        $category_color = '#FFFFFF'; 
    42         $category_image = ''; 
     42        $category_image = $category_image_id = ''; 
    4343        if( $tag != EM_TAXONOMY_CATEGORY ){ //not an add new tag form 
    4444            $EM_Category = new EM_Category($tag); 
  • events-manager/trunk/classes/em-event.php

    r1660386 r1677796  
    425425        } 
    426426         
    427         //Dates and Times - ignored if event is recurring being updated (not new) and not specifically chosen to reschedule event 
     427        //Dates and Times - dates ignored if event is recurring being updated (not new) and not specifically chosen to reschedule event 
    428428        if( !$this->is_recurring() || (empty($this->event_id) || !empty($_REQUEST['event_reschedule'])) ){ 
    429429            //Event Dates 
    430430            $this->event_start_date = ( !empty($_POST['event_start_date']) ) ? wp_kses_data($_POST['event_start_date']) : ''; 
    431431            $this->event_end_date = ( !empty($_POST['event_end_date']) ) ? wp_kses_data($_POST['event_end_date']) : $this->event_start_date; 
    432             //Sort out time 
    433             $this->event_all_day = ( !empty($_POST['event_all_day']) ) ? 1 : 0; 
    434             if( $this->event_all_day ){ 
    435                 $times_array = array('event_rsvp_time'); 
    436                 $this->event_start_time = '00:00:00'; 
    437                 $this->event_end_time = '23:59:59'; 
     432        } 
     433        //Sort out time 
     434        $this->event_all_day = ( !empty($_POST['event_all_day']) ) ? 1 : 0; 
     435        if( $this->event_all_day ){ 
     436            $times_array = array('event_rsvp_time'); 
     437            $this->event_start_time = '00:00:00'; 
     438            $this->event_end_time = '23:59:59'; 
     439        }else{ 
     440            $times_array = array('event_start_time','event_end_time', 'event_rsvp_time'); 
     441        } 
     442        foreach( $times_array as $timeName ){ 
     443            $match = array(); 
     444            if( !empty($_POST[$timeName]) && preg_match ( '/^([01]\d|[0-9]|2[0-3])(:([0-5]\d))? ?(AM|PM)?$/', $_POST[$timeName], $match ) ){ 
     445                if( empty($match[3]) ) $match[3] = '00'; 
     446                if( strlen($match[1]) == 1 ) $match[1] = '0'.$match[1]; 
     447                if( !empty($match[4]) && $match[4] == 'PM' && $match[1] != 12 ){ 
     448                    $match[1] = 12+$match[1]; 
     449                }elseif( !empty($match[4]) && $match[4] == 'AM' && $match[1] == 12 ){ 
     450                    $match[1] = '00'; 
     451                } 
     452                $this->$timeName = $match[1].":".$match[3].":00"; 
    438453            }else{ 
    439                 $times_array = array('event_start_time','event_end_time', 'event_rsvp_time'); 
    440             } 
    441             foreach( $times_array as $timeName ){ 
    442                 $match = array(); 
    443                 if( !empty($_POST[$timeName]) && preg_match ( '/^([01]\d|[0-9]|2[0-3])(:([0-5]\d))? ?(AM|PM)?$/', $_POST[$timeName], $match ) ){ 
    444                     if( empty($match[3]) ) $match[3] = '00'; 
    445                     if( strlen($match[1]) == 1 ) $match[1] = '0'.$match[1]; 
    446                     if( !empty($match[4]) && $match[4] == 'PM' && $match[1] != 12 ){ 
    447                         $match[1] = 12+$match[1]; 
    448                     }elseif( !empty($match[4]) && $match[4] == 'AM' && $match[1] == 12 ){ 
    449                         $match[1] = '00'; 
    450                     } 
    451                     $this->$timeName = $match[1].":".$match[3].":00"; 
    452                 }else{ 
    453                     $this->$timeName = ($timeName == 'event_start_time') ? "00:00:00":$this->event_start_time; 
    454                 } 
    455             } 
    456             //Start/End times should be available as timestamp 
    457             $this->start = strtotime($this->event_start_date." ".$this->event_start_time); 
    458             $this->end = strtotime($this->event_end_date." ".$this->event_end_time); 
    459         } 
     454                $this->$timeName = ($timeName == 'event_start_time') ? "00:00:00":$this->event_start_time; 
     455            } 
     456        } 
     457        //Start/End times should be available as timestamp 
     458        $this->start = strtotime($this->event_start_date." ".$this->event_start_time); 
     459        $this->end = strtotime($this->event_end_date." ".$this->event_end_time); 
    460460         
    461461        //Get Location info 
     
    22832283                $meta_inserts = array(); 
    22842284                //now unset some vars we don't need to deal with since we're just updating data in the wp_em_events and posts table 
    2285                 unset( $event['event_date_created'], $event['recurrence_id'], $event['recurrence'], $event['event_start_date'], $event['event_end_date'], $event['event_start_time'], $event['event_end_time'] ); 
     2285                unset( $event['event_date_created'], $event['recurrence_id'], $event['recurrence'], $event['event_start_date'], $event['event_end_date'] ); 
    22862286                $event['event_date_modified'] = current_time('mysql'); //since the recurrences are modified but not recreated 
    22872287                unset( $post_fields['comment_count'], $post_fields['guid'], $post_fields['menu_order']); 
     
    23062306                    $meta_fields['_event_start_date'] = $EM_Event->event_start_date; 
    23072307                    $meta_fields['_event_end_date'] = $EM_Event->event_end_date; 
    2308                     $meta_fields['_start_ts'] = $EM_Event->start; 
    2309                     $meta_fields['_end_ts'] = $EM_Event->end; 
     2308                    $meta_fields['_start_ts'] = strtotime($EM_Event->event_start_date." ".$this->event_start_time); 
     2309                    $meta_fields['_end_ts'] = strtotime($EM_Event->event_end_date." ".$this->event_end_time); 
    23102310                    //overwrite event and post tables 
    23112311                    $wpdb->update(EM_EVENTS_TABLE, $event, array('event_id' => $EM_Event->event_id)); 
     
    25332533                    } 
    25342534                    //Now grab from the array the x day of the month 
    2535                     $matching_day = ($this->recurrence_byweekno > 0) ? $matching_month_days[$this->recurrence_byweekno-1] : array_pop($matching_month_days); 
    2536                     $matching_date = strtotime(date('Y-m',$current_date).'-'.$matching_day); 
    2537                     if($matching_date >= $start_date && $matching_date <= $end_date){ 
    2538                         $matching_days[] = $matching_date; 
     2535                    $matching_day = false; 
     2536                    if( $this->recurrence_byweekno > 0 ){ 
     2537                        if( !empty($matching_month_days[$this->recurrence_byweekno-1]) ){ 
     2538                            $matching_day = $matching_month_days[$this->recurrence_byweekno-1]; 
     2539                        } 
     2540                    }else{ 
     2541                        $matching_day = array_pop($matching_month_days); 
     2542                    } 
     2543                    if( !empty($matching_day) ){ 
     2544                        $matching_date = strtotime(date('Y-m',$current_date).'-'.$matching_day); 
     2545                        if($matching_date >= $start_date && $matching_date <= $end_date){ 
     2546                            $matching_days[] = $matching_date; 
     2547                        } 
    25392548                    } 
    25402549                    //add the number of days in this month to make start of next month 
     
    25882597        $recurrence = $this->to_array(); 
    25892598        $weekdays_name = array( translate('Sunday'),translate('Monday'),translate('Tuesday'),translate('Wednesday'),translate('Thursday'),translate('Friday'),translate('Saturday')); 
    2590         $monthweek_name = array('1' => __('the first %s of the month', 'events-manager'),'2' => __('the second %s of the month', 'events-manager'), '3' => __('the third %s of the month', 'events-manager'), '4' => __('the fourth %s of the month', 'events-manager'), '-1' => __('the last %s of the month', 'events-manager')); 
     2599        $monthweek_name = array('1' => __('the first %s of the month', 'events-manager'),'2' => __('the second %s of the month', 'events-manager'), '3' => __('the third %s of the month', 'events-manager'), '4' => __('the fourth %s of the month', 'events-manager'), '5' => __('the fifth %s of the month', 'events-manager'), '-1' => __('the last %s of the month', 'events-manager')); 
    25912600        $output = sprintf (__('From %1$s to %2$s', 'events-manager'),  $EM_Event_Recurring->event_start_date, $EM_Event_Recurring->event_end_date).", "; 
    25922601        if ($EM_Event_Recurring->recurrence_freq == 'daily')  { 
  • events-manager/trunk/em-shortcode.php

    r1657109 r1677796  
    4040    //assign random number for element id reference 
    4141    $args['random_id'] = substr(md5(rand().rand()),0,5); 
     42    //add JSON style to map 
     43    $style = ''; 
    4244    if( !empty($args['map_style']) ){ 
    4345        $style= base64_decode($args['map_style']); 
     
    7577    //assign random number for element id reference 
    7678    $args['random_id'] = substr(md5(rand().rand()),0,5); 
     79    //add JSON style to map 
     80    $style = ''; 
    7781    if( !empty($args['map_style']) ){ 
    7882        $style= base64_decode($args['map_style']); 
  • events-manager/trunk/events-manager.php

    r1660386 r1677796  
    22/* 
    33Plugin Name: Events Manager 
    4 Version: 5.7.2.2 
     4Version: 5.7.3 
    55Plugin URI: http://wp-events-plugin.com 
    66Description: Event registration and booking management for WordPress. Recurring events, locations, google maps, rss, ical, booking registration and more! 
  • events-manager/trunk/includes/css/events_manager.css

    r1651260 r1677796  
    2020            width:auto; height:auto; margin:0; padding:0; float:none; display:inline-block; font-size:14px; /* reset everything */ 
    2121        } 
     22        div.css-search option { display:block; } 
    2223        div.css-search input, div.css-search select { padding:5px; } 
    2324        div.css-search { background:#fff; border:1px solid #dedede; border-radius:3px; padding:5px; min-height:40px; position:relative; -moz-border-radius:3px; -webkit-border-radius:3px; }     
  • events-manager/trunk/readme.txt

    r1660386 r1677796  
    55Text Domain: events-manager 
    66Requires at least: 3.5 
    7 Tested up to: 4.7.4 
    8 Stable tag: 5.7.2 
     7Tested up to: 4.8 
     8Stable tag: 5.7.3 
    99 
    1010Fully featured event registration management including recurring events, locations management, calendar, Google map integration, booking management 
     
    100100 
    101101== Changelog == 
    102 = 5.7.2.2 (dev) = 
     102= 5.7.3 = 
    103103* fixed previous meta not getting deleted from recurrences resulting in non-saved information such as a changed featured image or location 
    104 * fixed newly submitted recurrences first saved in draft or pending mode not creating new events without a reschedule  
     104* fixed newly submitted recurrences first saved in draft or pending mode not creating new events without a reschedule 
     105* fixed export settings button not working in MultiSite 
     106* fixed CSS issue in search form advanced field dropdowns on firefox 
     107* fixed PHP warning when displaying locations and events map via shortcode (kudos @Beee)  
     108* fixed minor PHP warning on category admin pages where image isn't defined (kudos @Beee) 
     109* fixed booking admin 'Add Note' button not being translatable 
     110* added fifth day of month in recurrences pattern 
     111* added ability to change event times on recurring events without recreating recurrences 
    105112 
    106113= 5.7.2 = 
  • events-manager/trunk/templates/forms/event/recurring-when.php

    r1651260 r1677796  
    66$classes = array(); 
    77?> 
    8 <!-- START recurrence postbox --> 
    9 <div id="em-form-recurrence" class="event-form-recurrence event-form-when <?php if( !empty($EM_Event->event_id) ) echo 'em-recurrence-reschedule'; ?>"> 
     8<div id="em-form-recurrence" class="event-form-recurrence event-form-when"> 
     9    <p class="em-time-range"> 
     10        <?php _e('Events start from','events-manager'); ?> 
     11        <input id="start-time" class="em-time-input em-time-start" type="text" size="8" maxlength="8" name="event_start_time" value="<?php echo date( $hours_format, $EM_Event->start ); ?>" /> 
     12        <?php _e('to','events-manager'); ?> 
     13        <input id="end-time" class="em-time-input em-time-end" type="text" size="8" maxlength="8" name="event_end_time" value="<?php echo date( $hours_format, $EM_Event->end ); ?>" /> 
     14        <?php _e('All day','events-manager'); ?> <input type="checkbox" class="em-time-allday" name="event_all_day" id="em-time-all-day" value="1" <?php if(!empty($EM_Event->event_all_day)) echo 'checked="checked"'; ?> /> 
     15    </p> 
     16    <div class="<?php if( !empty($EM_Event->event_id) ) echo 'em-recurrence-reschedule'; ?>"> 
    1017    <?php if( !empty($EM_Event->event_id) ): ?> 
    1118    <div class="recurrence-reschedule-warning"> 
    1219        <p><em><?php echo sprintf(esc_html__('Current Recurrence Pattern: %s', 'events-manager'), $EM_Event->get_recurrence_description()); ?></em></p> 
    13         <p><strong><?php esc_html_e( 'Modifications to event times will cause all recurrences of this event to be deleted and recreated, previous bookings will be deleted.', 'events-manager'); ?></strong></p> 
     20        <p><strong><?php esc_html_e( 'Modifications to event dates will cause all recurrences of this event to be deleted and recreated, previous bookings will be deleted.', 'events-manager'); ?></strong></p> 
    1421        <p> 
    1522           <a href="<?php echo esc_url( add_query_arg(array('scope'=>'all', 'recurrence_id'=>$EM_Event->event_id), em_get_events_admin_url()) ); ?>"> 
     
    4653            <select id="monthly-modifier" name="recurrence_byweekno"> 
    4754                <?php 
    48                     $weekno_options = array ("1" => __ ( 'first', 'events-manager'), '2' => __ ( 'second', 'events-manager'), '3' => __ ( 'third', 'events-manager'), '4' => __ ( 'fourth', 'events-manager'), '-1' => __ ( 'last', 'events-manager') );  
     55                    $weekno_options = array ("1" => __ ( 'first', 'events-manager'), '2' => __ ( 'second', 'events-manager'), '3' => __ ( 'third', 'events-manager'), '4' => __ ( 'fourth', 'events-manager'), '5' => __ ( 'fifth', 'events-manager'), '-1' => __ ( 'last', 'events-manager') );  
    4956                    em_option_items ( $weekno_options, $EM_Event->recurrence_byweekno  );  
    5057                ?> 
     
    6572                <input class="em-date-input" type="hidden" name="event_end_date" value="<?php echo $EM_Event->event_end_date ?>" /> 
    6673            </p> 
    67             <p class="em-time-range"> 
    68                 <?php _e('Events start from','events-manager'); ?> 
    69                 <input id="start-time" class="em-time-input em-time-start" type="text" size="8" maxlength="8" name="event_start_time" value="<?php echo date( $hours_format, $EM_Event->start ); ?>" /> 
    70                 <?php _e('to','events-manager'); ?> 
    71                 <input id="end-time" class="em-time-input em-time-end" type="text" size="8" maxlength="8" name="event_end_time" value="<?php echo date( $hours_format, $EM_Event->end ); ?>" /> 
    72                 <?php _e('All day','events-manager'); ?> <input type="checkbox" class="em-time-allday" name="event_all_day" id="em-time-all-day" value="1" <?php if(!empty($EM_Event->event_all_day)) echo 'checked="checked"'; ?> /> 
    73             </p> 
    7474            <p class="em-duration-range"> 
    7575                <?php echo sprintf(__('Each event spans %s day(s)','events-manager'), '<input id="end-days" type="text" size="8" maxlength="8" name="recurrence_days" value="'. $EM_Event->recurrence_days .'" />'); ?> 
     
    8989    </div> 
    9090    <?php endif; ?> 
     91    </div> 
    9192</div> 
Note: See TracChangeset for help on using the changeset viewer.