PluginProbe
Timetics – Appointment Booking Calendar & Scheduling / 1.0.49
Timetics – Appointment Booking Calendar & Scheduling v1.0.49
1.0.61 1.0.60 1.0.59 1.0.58 1.0.57 1.0.56 trunk 1.0.0 1.0.1 1.0.10 1.0.11 1.0.12 1.0.13 1.0.14 1.0.15 1.0.16 1.0.17 1.0.18 1.0.19 1.0.2 1.0.20 1.0.21 1.0.22 1.0.23 1.0.24 All 62 releases
← All changes | core/frontend/shortcode.php +7 -9 trunk1.0.49 View file →
@@ -6,10 +6,8 @@
6 6 */
7 7
8 8 namespace Timetics\Core\Frontend;
9 9
10 -defined( 'ABSPATH' ) || exit;
11 -
12 10 use Timetics\Utils\Singleton;
13 11 use Timetics;
14 12
15 13 /**
@@ -56,9 +54,9 @@
56 54 $id = isset( $attribute['id'] ) ? $attribute['id'] : '';
57 55 $data_controls = [
58 56 'id' => $id,
59 57 ];
60 - $controls = wp_json_encode( $data_controls );
58 + $controls = json_encode( $data_controls );
61 59
62 60 $visibility = get_post_meta( $id, '_tt_apointment_visibility', true );
63 61 $is_visible = 'enabled' === $visibility;
64 62
@@ -88,9 +86,9 @@
88 86 $id = get_current_user_id();
89 87 $data_controls = [
90 88 'id' => $id,
91 89 ];
92 - $controls = wp_json_encode( $data_controls );
90 + $controls = json_encode( $data_controls );
93 91
94 92 ob_start();
95 93 if (is_user_logged_in()) {
96 94
@@ -104,9 +102,9 @@
104 102
105 103 }else{
106 104 ?>
107 105 <div class="timetics-userdashbaord-wrapper">
108 - <h3> <?php esc_html_e( 'You are not logged in', 'timetics' ); ?> <a href="<?php echo esc_url( wp_login_url( get_permalink() ) ); ?>"><?php esc_html_e( 'Login', 'timetics' ); ?></a></h3>
106 + <h3> <?php esc_html_e( 'You are not logged in', 'timetics' ); ?> <a href="<?php echo esc_url(wp_login_url()) ?>"><?php esc_html_e( 'Login', 'timetics' ); ?></a></h3>
109 107 </div>
110 108 <?php
111 109 }
112 110 return ob_get_clean();
@@ -132,12 +130,12 @@
132 130 wp_enqueue_script( 'timetics-frontend-scripts' );
133 131 wp_enqueue_script( 'calendar-locale' );
134 132 wp_enqueue_script( 'jquery' );
135 133
136 - wp_enqueue_script( 'timetics-meeting-filtering', TIMETICS_ASSETS_URL . 'js/meeting-filter.js', ['jquery'], time(), true );
134 + wp_enqueue_script( 'timetics-meeting-filtering', TIMETICS_ASSETS_URL . 'js/meeting-filter.js', ['jquery'], time() );
137 135
138 - $timetics_limit = isset( $attribute['limit'] ) ? $attribute['limit'] : '';
139 - $timetics_show_filter = isset( $attribute['show_filter'] ) && 'true' == $attribute['show_filter'] ? $attribute['show_filter'] : false;
136 + $limit = isset( $attribute['limit'] ) ? $attribute['limit'] : '';
137 + $show_filter = isset( $attribute['show_filter'] ) && 'true' == $attribute['show_filter'] ? $attribute['show_filter'] : false;
140 138
141 139 ob_start();
142 140 ?>
143 141 <div class="timetics-shortcode-wrapper">
@@ -168,9 +166,9 @@
168 166 $id = isset( $attribute['id'] ) ? $attribute['id'] : '';
169 167 $data_controls = [
170 168 'id' => $id,
171 169 ];
172 - $controls = wp_json_encode( $data_controls );
170 + $controls = json_encode( $data_controls );
173 171
174 172 ob_start();
175 173 ?>
176 174 <div class="timetics-shortcode-wrapper">