| @@ -1,5 +1,8 @@ | ||
| 1 | -<?php $id = $settings->template;//phpcs:ignore WordPress.WP.GlobalVariablesOverride.Prohibited ?> | |
| 1 | +<?php | |
| 2 | +defined( 'ABSPATH' ) || exit; | |
| 3 | +// phpcs:disable WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedVariableFound -- Included by Beaver Builder inside the module render method; variables are local. | |
| 4 | +$id = $settings->template;//phpcs:ignore WordPress.WP.GlobalVariablesOverride.Prohibited ?> | |
| 2 | 5 | <div class="ultp-shortcode" data-postid="<?php echo esc_attr( $id ); ?>"> |
| 3 | 6 | <?php |
| 4 | 7 | if ( $id ) { |
| 5 | 8 | $args = array( |
| @@ -13,9 +16,9 @@ | ||
| 13 | 16 | the_content(); |
| 14 | 17 | } |
| 15 | 18 | wp_reset_postdata(); |
| 16 | 19 | } |
| 17 | - } elseif ( isset( $_GET['fl_builder'] ) ) { | |
| 20 | + } elseif ( isset( $_GET['fl_builder'] ) ) { // phpcs:ignore WordPress.Security.NonceVerification.Recommended -- Read-only Beaver Builder editor detection. | |
| 18 | 21 | //phpcs:ignore |
| 19 | 22 | echo '<p style="text-align:center;">' . sprintf( esc_html__( 'Pick a Template from your saved ones. Or create a template from: %s.', 'ultimate-post' ) . ' ', '<strong><i>' . esc_html__( 'Dashboard > PostX > Saved Templates', 'ultimate-post' ) . '</i></strong>' ) . '</p>'; //phpcs:ignore |
| 20 | 23 | |
| 21 | 24 | } |