| @@ -29,9 +29,9 @@ | ||
| 29 | 29 | |
| 30 | 30 | public function get_renewal_text(): array { |
| 31 | 31 | if ( $this->days_diff <= 30 && $this->days_diff > 0 ) { |
| 32 | 32 | return [ |
| 33 | - 'title' => esc_html__( 'Image Optimizer Expires Soon!', 'image-optimization' ), | |
| 33 | + 'title' => esc_html__( 'Image Optimization Expires Soon!', 'image-optimization' ), | |
| 34 | 34 | 'description' => esc_html__( 'Renew your subscription to maintain optimized images, faster website load times, and high performance.', 'image-optimization' ), |
| 35 | 35 | 'btn' => esc_html__( 'Turn Auto Renew On', 'image-optimization' ), |
| 36 | 36 | 'link' => esc_url( 'https://go.elementor.com/io-renew-30/' ), |
| 37 | 37 | ]; |
| @@ -37,9 +37,9 @@ | ||
| 37 | 37 | ]; |
| 38 | 38 | } |
| 39 | 39 | if ( $this->days_diff <= 0 && $this->days_diff > -7 ) { |
| 40 | 40 | return [ |
| 41 | - 'title' => esc_html__( 'Image Optimizer Has Expired!', 'image-optimization' ), | |
| 41 | + 'title' => esc_html__( 'Image Optimization Has Expired!', 'image-optimization' ), | |
| 42 | 42 | 'description' => esc_html__( 'Renew your license today to continue enjoying premium image optimization and fast load times.', 'image-optimization' ), |
| 43 | 43 | 'btn' => esc_html__( 'Renew Now', 'image-optimization' ), |
| 44 | 44 | 'link' => esc_url( 'https://go.elementor.com/io-renew-expire/' ), |
| 45 | 45 | ]; |
| @@ -44,9 +44,9 @@ | ||
| 44 | 44 | 'link' => esc_url( 'https://go.elementor.com/io-renew-expire/' ), |
| 45 | 45 | ]; |
| 46 | 46 | } |
| 47 | 47 | return [ |
| 48 | - 'title' => esc_html__( 'It’s Not Too Late! Renew Image Optimizer', 'image-optimization' ), | |
| 48 | + 'title' => esc_html__( 'It’s Not Too Late! Renew Image Optimization', 'image-optimization' ), | |
| 49 | 49 | 'description' => esc_html__( 'Reactivate your license to get back to top image performance.', 'image-optimization' ), |
| 50 | 50 | 'btn' => esc_html__( 'Renew and Optimize', 'image-optimization' ), |
| 51 | 51 | 'link' => esc_url( 'https://go.elementor.com/io-renew-post-expire/' ), |
| 52 | 52 | ]; |
| @@ -63,17 +63,17 @@ | ||
| 63 | 63 | <path fill="#fff" d="M10.508 4.135a.125.125 0 0 0-.236 0l-1.183 3.42a.125.125 0 0 1-.078.078L5.553 8.8a.125.125 0 0 0 0 .237l3.458 1.166a.125.125 0 0 1 .078.078l1.183 3.42a.125.125 0 0 0 .236 0l1.182-3.42a.125.125 0 0 1 .078-.078l3.458-1.166a.125.125 0 0 0 0-.237l-3.458-1.167a.125.125 0 0 1-.078-.077l-1.182-3.421ZM17.425 12.738v3.683l-4.073 4.582L26.495 9.598a.125.125 0 0 1 .207.094v14.851a.125.125 0 0 1-.125.125H5.874a.125.125 0 0 1-.09-.212l11.427-11.805a.125.125 0 0 1 .214.087Z"/> |
| 64 | 64 | </svg> |
| 65 | 65 | <p> |
| 66 | 66 | <b> |
| 67 | - <?php echo $text['title']; ?> | |
| 67 | + <?php echo esc_html( $text['title'] ); ?> | |
| 68 | 68 | </b> |
| 69 | 69 | <span> |
| 70 | - <?php echo $text['description']; ?> | |
| 70 | + <?php echo esc_html( $text['description'] ); ?> | |
| 71 | 71 | </span> |
| 72 | 72 | </p> |
| 73 | 73 | </div> |
| 74 | - <a href="<?php echo $text['link']; ?>" target="_blank" rel="noopener noreferrer"> | |
| 75 | - <?php echo $text['btn']; ?> | |
| 74 | + <a href="<?php echo esc_url( $text['link'] ); ?>" target="_blank" rel="noopener noreferrer"> | |
| 75 | + <?php echo esc_html( $text['btn'] ); ?> | |
| 76 | 76 | </a> |
| 77 | 77 | </div> |
| 78 | 78 | |
| 79 | 79 | <script> |
| @@ -79,9 +79,9 @@ | ||
| 79 | 79 | <script> |
| 80 | 80 | jQuery( document ).ready( function( $ ) { |
| 81 | 81 | setTimeout(() => { |
| 82 | 82 | const $msInOneDay = 24 * 60 * 60 * 1000; |
| 83 | - const $time_dismissed = localStorage.getItem('<?php echo self::RENEWAL_NOTICE_SLUG; ?>'); | |
| 83 | + const $time_dismissed = localStorage.getItem('<?php echo esc_js( self::RENEWAL_NOTICE_SLUG ); ?>'); | |
| 84 | 84 | const $show_notice = !$time_dismissed || Date.now() - $time_dismissed >= $msInOneDay; |
| 85 | 85 | |
| 86 | 86 | const $notice = $( '[data-notice-slug="<?php echo esc_js( self::RENEWAL_NOTICE_SLUG ); ?>"]' ); |
| 87 | 87 | const $closeButton = $( '[data-notice-slug="<?php echo esc_js( self::RENEWAL_NOTICE_SLUG ); ?>"] .notice-dismiss' ); |