| @@ -1,8 +1,8 @@ | ||
| 1 | 1 | <?php |
| 2 | 2 | defined( 'ABSPATH' ) || exit; |
| 3 | 3 | |
| 4 | -class Gutenberg_Post_Blocks_Widget extends \Elementor\Widget_Base { | |
| 4 | +class ULTP_Elementor_Post_Blocks_Widget extends \Elementor\Widget_Base { | |
| 5 | 5 | |
| 6 | 6 | public function get_name() { |
| 7 | 7 | return 'gutenberg-post-blocks'; |
| 8 | 8 | } |
| @@ -58,9 +58,9 @@ | ||
| 58 | 58 | $id = $settings['saved_template']; |
| 59 | 59 | |
| 60 | 60 | if ( $id ) { |
| 61 | 61 | if ( isset( $_GET['action'] ) || isset( $_POST['action'] ) ) { //phpcs:ignore WordPress.Security.NonceVerification.Missing,WordPress.Security.NonceVerification.Recommended |
| 62 | - echo ultimate_post()->build_css_for_inline_print( $id, true ); //phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped | |
| 62 | + echo ultimate_post()->build_css_for_inline_print( $id, true ); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped -- <style> tag from build_css_for_inline_print(): integer post ID, CSS passed through wp_strip_all_tags(). | |
| 63 | 63 | } |
| 64 | 64 | echo '<div class="ultp-shortcode" data-postid="' . esc_attr( $id ) . '">'; |
| 65 | 65 | $args = array( |
| 66 | 66 | 'p' => $id, |
| @@ -74,10 +74,10 @@ | ||
| 74 | 74 | } |
| 75 | 75 | wp_reset_postdata(); |
| 76 | 76 | } |
| 77 | 77 | echo '</div>'; |
| 78 | - } elseif ( isset( $_GET['action'] ) && $_GET['action'] == 'elementor' ) { | |
| 79 | - // phpcs:ignore WordPress.Security.NonceVerification.Missing,WordPress.Security.NonceVerification.Recommended | |
| 78 | + } elseif ( isset( $_GET['action'] ) && $_GET['action'] == 'elementor' ) { // phpcs:ignore WordPress.Security.NonceVerification.Recommended -- Read-only check for the Elementor editor screen. | |
| 79 | + /* translators: %s: Menu path to the Saved Templates screen. */ | |
| 80 | 80 | 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>'; |
| 81 | 81 | } |
| 82 | 82 | } |
| 83 | 83 | } |