PluginProbe
LearnPress – WordPress LMS Plugin for Create and Sell Online Courses / 4.4.8
LearnPress – WordPress LMS Plugin for Create and Sell Online Courses v4.4.8
4.4.8 4.4.7 4.4.6 4.4.5 4.4.4 4.4.3 4.4.2 4.4.1 4.4.0 4.3.9.1 4.3.9 4.3.8 4.3.7 4.1.6.9 4.1.6.9.1 4.1.6.9.2 4.1.6.9.3 4.1.6.9.4 4.1.7 4.1.7.1 4.1.7.2 4.1.7.3 4.1.7.3.1 4.1.7.3.2 4.2.0 All 139 releases
← All changes | inc/admin/meta-box/fields/toggle-switch.php +24 -24 4.3.9.14.4.8 View file →
@@ -1,24 +1,24 @@
1 -<?php
2 -/**
3 - * Template show toggle switch field
4 - */
5 -
6 -defined( 'ABSPATH' ) || exit();
7 -
8 -if ( ! isset( $data ) ) {
9 - return;
10 -}
11 -?>
12 -<div class="lp-toggle-switch">
13 - <input class="lp-toggle-switch-input"
14 - name="<?php echo esc_attr( $data['name'] ?? '' ); ?>"
15 - id="<?php echo esc_attr( $data['id'] ?? '' ); ?>"
16 - <?php echo esc_attr( $data['value'] ? 'checked' : '' ); ?>
17 - type="checkbox" value="<?php echo esc_attr( $data['value'] ?? 0 ); ?>"
18 - <?php echo sanitize_text_field( $data['extra'] ?? '' ); ?>>
19 - <label class="lp-toggle-switch-label" for="<?php echo esc_attr( $data['id'] ?? '' ); ?>">
20 - <span class="toggle-on"></span>
21 - <span class="toggle-off"></span>
22 - </label>
23 - <span class="dashicons dashicons-update" style="display: none"></span>
24 -</div>
1 +<?php
2 +/**
3 + * Template show toggle switch field
4 + */
5 +
6 +defined( 'ABSPATH' ) || exit();
7 +
8 +if ( ! isset( $data ) ) {
9 + return;
10 +}
11 +?>
12 +<div class="lp-toggle-switch">
13 + <input class="lp-toggle-switch-input"
14 + name="<?php echo esc_attr( $data['name'] ?? '' ); ?>"
15 + id="<?php echo esc_attr( $data['id'] ?? '' ); ?>"
16 + <?php echo esc_attr( $data['value'] ? 'checked' : '' ); ?>
17 + type="checkbox" value="<?php echo esc_attr( $data['value'] ?? 0 ); ?>"
18 + <?php echo sanitize_text_field( $data['extra'] ?? '' ); ?>>
19 + <label class="lp-toggle-switch-label" for="<?php echo esc_attr( $data['id'] ?? '' ); ?>">
20 + <span class="toggle-on"></span>
21 + <span class="toggle-off"></span>
22 + </label>
23 + <span class="dashicons dashicons-update" style="display: none"></span>
24 +</div>