PluginProbe
Booking Calendar / 11.8.3
Booking Calendar v11.8.3
11.8.3 11.8.2 11.8.1 11.8 11.7 11.6.1 11.6 11.5 11.4.3 11.4.2 11.4.1 11.4 11.3 11.2.1 11.2 11.1 11.0 10.15.7 10.15.6 10.1.3 10.10 10.10.1 10.10.2 10.11 10.11.2 All 203 releases
← All changes | includes/_feedback/feedback.php +20 -18 11.111.8.3 View file →
@@ -17,15 +17,15 @@
17 17 if ( ! defined( 'WPBC_FEEDBACK_TIMEOUT' ) ) { define( 'WPBC_FEEDBACK_TIMEOUT', '+2 days' ); }
18 18 //if ( ! defined( 'WPBC_FEEDBACK_TIMEOUT' ) ) { define( 'WPBC_FEEDBACK_TIMEOUT', '+30 seconds' ); }
19 19
20 20 // == For testing ==
21 -//update_option( 'booking_feedback_03', gmdate( 'Y-m-d H:i:s', strtotime( '+10 seconds', strtotime( 'now' ) ) ) );
21 +//update_option( 'booking_feedback_04', gmdate( 'Y-m-d H:i:s', strtotime( '+10 seconds', strtotime( 'now' ) ) ) );
22 22
23 23 // Init Timer
24 -// update_option( 'booking_feedback_03', gmdate( 'Y-m-d H:i:s', strtotime( WPBC_FEEDBACK_TIMEOUT, strtotime( 'now' ) ) ) );
24 +// update_option( 'booking_feedback_04', gmdate( 'Y-m-d H:i:s', strtotime( WPBC_FEEDBACK_TIMEOUT, strtotime( 'now' ) ) ) );
25 25
26 26 // Reset
27 -// delete_option( 'booking_feedback_03');
27 +// delete_option( 'booking_feedback_04');
28 28
29 29 function wpbc_get_feedback_defaults( $param_name ){
30 30
31 31 $defaults = array(
@@ -185,9 +185,9 @@
185 185 return false;
186 186 }
187 187
188 188 if ( wpbc_is__feedback_01__timeout_need_to_show() ) { // Check if time go out
189 - update_option( 'booking_feedback_03', '' );
189 + update_option( 'booking_feedback_04', '' );
190 190 } else {
191 191 return false;
192 192 }
193 193
@@ -440,15 +440,15 @@
440 440 $after_action_message = __( 'Done', 'booking' );
441 441
442 442 // Update new period for showing Feedback
443 443 $feedback_date = gmdate('Y-m-d H:i:s', strtotime( WPBC_FEEDBACK_TIMEOUT, strtotime( 'now' ) ) );
444 - update_option('booking_feedback_03', $feedback_date );
444 + update_option('booking_feedback_04', $feedback_date );
445 445
446 446 } elseif ( ( $feedback_stars > 0 ) && ( $feedback_stars <= 5 ) ) {
447 447
448 448 // Send email
449 449 wpbc_feedback_01__send_email( $feedback_stars, $feedback__note );
450 - update_option('booking_feedback_03_rating', $feedback_stars );
450 + update_option('booking_feedback_04_rating', $feedback_stars );
451 451
452 452 }
453 453
454 454 if ( ( 5 == $feedback_stars ) && ( 'rate5' != $feedback__note ) ) {
@@ -543,18 +543,20 @@
543 543 * @return string
544 544 */
545 545 function wpbc_feedback_01_get_version(){
546 546
547 - if ( substr( WPDEV_BK_VERSION, 0, 3 ) == '11.' ) {
548 - $show_version = substr( WPDEV_BK_VERSION, 3 );
549 - if ( substr( $show_version, ( - 1 * ( strlen( WP_BK_VERSION_NUM ) ) ) ) === WP_BK_VERSION_NUM ) {
550 - $show_version = substr( $show_version, 0, ( - 1 * ( strlen( WP_BK_VERSION_NUM ) ) - 1 ) );
551 - $show_version = str_replace( '.', ' ', $show_version ) . ' ' . WP_BK_VERSION_NUM;
552 - }
547 + // if ( substr( WPDEV_BK_VERSION, 0, 3 ) == '11.' ) {
548 + // $show_version = substr( WPDEV_BK_VERSION, 3 );
549 + // if ( substr( $show_version, ( - 1 * ( strlen( WP_BK_VERSION_NUM ) ) ) ) === WP_BK_VERSION_NUM ) {
550 + // $show_version = substr( $show_version, 0, ( - 1 * ( strlen( WP_BK_VERSION_NUM ) ) - 1 ) );
551 + // $show_version = str_replace( '.', ' ', $show_version ) . ' ' . WP_BK_VERSION_NUM;
552 + // }
553 + //
554 + // } else {
555 + // $show_version = WPDEV_BK_VERSION;
556 + // }
553 557
554 - } else {
555 - $show_version = WPDEV_BK_VERSION;
556 - }
558 + $show_version = wpbc_get_wpbc_versions_numbers();
557 559
558 560 $ver = wpbc_get_plugin_version_type();
559 561 if ( class_exists( 'wpdev_bk_multiuser' ) ) {
560 562 $ver = 'MultiUser';
@@ -591,9 +593,9 @@
591 593 function wpbc_is__feedback_01__timeout_need_to_show() {
592 594
593 595 //return true;
594 596
595 - $feedback_01_date = get_option( 'booking_feedback_03' );
597 + $feedback_01_date = get_option( 'booking_feedback_04' );
596 598
597 599 if (
598 600 ( ! empty( $feedback_01_date ) )
599 601 && ( ( strtotime( 'now' ) - strtotime( $feedback_01_date ) ) > 0 )
@@ -617,9 +619,9 @@
617 619 if ( version_compare( WP_BK_VERSION_NUM, wpbc_get_feedback_defaults( 'max_version' ) , '>=') ) {
618 620 return false;
619 621 }
620 622 $feedback_date = gmdate( 'Y-m-d H:i:s', strtotime( WPBC_FEEDBACK_TIMEOUT, strtotime( 'now' ) ) );
621 - add_option( 'booking_feedback_03', $feedback_date );
623 + add_option( 'booking_feedback_04', $feedback_date );
622 624 }
623 625 add_bk_action( 'wpbc_before_activation' , 'wpbc_is__feedback_01__timer_install' );
624 626
625 627
@@ -632,8 +634,8 @@
632 634 ) {
633 635 $wpbc_js_css_loading = new WPBC_Feedback_01;
634 636 $wpbc_js_css_loading->define_ajax_hook();
635 637
636 - if ( ! empty( get_option( 'booking_feedback_03' ) ) ){
638 + if ( ! empty( get_option( 'booking_feedback_04' ) ) ){
637 639 $wpbc_js_css_loading->init_load_css_js();
638 640 }
639 641 }