Changeset 3345192
- Timestamp:
- 08/15/2025 02:22:18 PM (8 months ago)
- Location:
- groundhogg
- Files:
-
- 18 edited
- 1 copied
-
tags/4.2.4.2 (copied) (copied from groundhogg/trunk)
-
tags/4.2.4.2/README.txt (modified) (2 diffs)
-
tags/4.2.4.2/groundhogg.php (modified) (2 diffs)
-
tags/4.2.4.2/includes/bulk-jobs/manager.php (modified) (1 diff)
-
tags/4.2.4.2/includes/functions.php (modified) (10 diffs)
-
tags/4.2.4.2/includes/utils/files.php (modified) (1 diff)
-
tags/4.2.4.2/templates/email/boxed.php (modified) (2 diffs)
-
tags/4.2.4.2/templates/email/full_width.php (modified) (2 diffs)
-
tags/4.2.4.2/templates/email/full_width_contained.php (modified) (3 diffs)
-
tags/4.2.4.2/templates/email/template-functions.php (modified) (2 diffs)
-
trunk/README.txt (modified) (2 diffs)
-
trunk/groundhogg.php (modified) (2 diffs)
-
trunk/includes/bulk-jobs/manager.php (modified) (1 diff)
-
trunk/includes/functions.php (modified) (10 diffs)
-
trunk/includes/utils/files.php (modified) (1 diff)
-
trunk/templates/email/boxed.php (modified) (2 diffs)
-
trunk/templates/email/full_width.php (modified) (2 diffs)
-
trunk/templates/email/full_width_contained.php (modified) (3 diffs)
-
trunk/templates/email/template-functions.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
groundhogg/tags/4.2.4.2/README.txt
r3344140 r3345192 7 7 Tested up to: 6.8 8 8 Requires PHP: 7.1 9 Stable tag: 4.2.4. 19 Stable tag: 4.2.4.2 10 10 License: GPLv3 11 11 License URI: https://www.gnu.org/licenses/gpl.md … … 374 374 375 375 == Changelog == 376 377 = 4.2.4.2 (2025-08-15) = 378 * TWEAKED Refactored usages of `file_get_contents()` to use the `WP_Filesystem` instead. 379 * FIXED Don't use `esc_html()` for CSS. You'd think WordPress core would have a better internal solution for outputting CSS 🙄 376 380 377 381 = 4.2.4.1 (2025-08-13) = -
groundhogg/tags/4.2.4.2/groundhogg.php
r3344140 r3345192 4 4 * Plugin URI: https://www.groundhogg.io/?utm_source=wp-plugins&utm_campaign=plugin-uri&utm_medium=wp-dash 5 5 * Description: CRM and marketing automation for WordPress 6 * Version: 4.2.4. 16 * Version: 4.2.4.2 7 7 * Author: Groundhogg Inc. 8 8 * Author URI: https://www.groundhogg.io/?utm_source=wp-plugins&utm_campaign=author-uri&utm_medium=wp-dash … … 25 25 if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly 26 26 27 define( 'GROUNDHOGG_VERSION', '4.2.4. 1' );28 define( 'GROUNDHOGG_PREVIOUS_STABLE_VERSION', '4.2. 3.1' );27 define( 'GROUNDHOGG_VERSION', '4.2.4.2' ); 28 define( 'GROUNDHOGG_PREVIOUS_STABLE_VERSION', '4.2.4.1' ); 29 29 30 30 define( 'GROUNDHOGG__FILE__', __FILE__ ); -
groundhogg/tags/4.2.4.2/includes/bulk-jobs/manager.php
r3343709 r3345192 41 41 } 42 42 43 44 43 /** 45 44 * Magic get method -
groundhogg/tags/4.2.4.2/includes/functions.php
r3343709 r3345192 1216 1216 case 'action': 1217 1217 case 'src': 1218 case 'background': 1218 1219 $value = strpos( $value, 'data:image/png;base64,' ) === false ? esc_url( $value ) : esc_attr( $value ); 1219 1220 break; … … 3664 3665 // check the time the file was created, if within our ttl, return the contents 3665 3666 if ( $time && $time > time() - $cache_ttl ) { 3666 $json = json_decode( @file_get_contents( $cached_file ), $as_array );3667 $json = json_decode( files()->get_contents( $cached_file ), $as_array ); 3667 3668 if ( ! empty( $json ) ) { 3668 3669 return $json; … … 3716 3717 // We don't cache errors... 3717 3718 if ( $cache_ttl !== 0 && $cache_key ) { 3718 @file_put_contents( files()->get_uploads_dir( 'requests', $cache_key . '.json', true ),json_encode( $json ) );3719 files()->put( files()->get_uploads_dir( 'requests', $cache_key . '.json', true ), wp_json_encode( $json ) ); 3719 3720 } 3720 3721 … … 4615 4616 function install_gh_cron_file() { 4616 4617 4617 $gh_cron_php = file _get_contents( GROUNDHOGG_PATH . 'gh-cron.txt' );4618 $bytes = file _put_contents( ABSPATH . 'gh-cron.php', $gh_cron_php );4618 $gh_cron_php = files()->get_contents( GROUNDHOGG_PATH . 'gh-cron.txt' ); 4619 $bytes = files()->put_contents( ABSPATH . 'gh-cron.php', $gh_cron_php ); 4619 4620 4620 4621 return (bool) $bytes; … … 4627 4628 */ 4628 4629 function uninstall_gh_cron_file() { 4629 return @unlink( ABSPATH . 'gh-cron.php' );4630 return wp_delete_file( ABSPATH . 'gh-cron.php' ); 4630 4631 } 4631 4632 … … 7395 7396 // initialize providers 7396 7397 if ( empty( $providers ) ) { 7397 $providers = json_decode( file _get_contents( GROUNDHOGG_ASSETS_PATH . 'lib/free-email-providers.json' ), true );7398 $providers = json_decode( files()->get( GROUNDHOGG_ASSETS_PATH . 'lib/free-email-providers.json' ), true ); 7398 7399 } 7399 7400 … … 8829 8830 8830 8831 // Read file content 8831 $content = file _get_contents( $file_path );8832 $content = files()->get_contents( $file_path ); 8832 8833 8833 8834 // Replace occurrences … … 8835 8836 8836 8837 // Write back to file 8837 return file _put_contents( $file_path, $updated_content ) !== false;8838 return files()->put_contents( $file_path, $updated_content ) !== false; 8838 8839 } 8839 8840 … … 9001 9002 function redact_meta_table( $table ) { 9002 9003 9003 global $wpdb;9004 9005 9004 $table = db()->get_db( $table ); 9006 9005 $table_name = $table->table_name; … … 9008 9007 9009 9008 $time = time(); 9010 9011 9009 9012 9010 global $wpdb; -
groundhogg/tags/4.2.4.2/includes/utils/files.php
r3343709 r3345192 6 6 7 7 class Files { 8 9 /** 10 * Proxy for filesystem()) 11 * 12 * @param $name 13 * @param $arguments 14 * 15 * @return mixed 16 */ 17 public function __call( $name, $arguments ) { 18 if ( method_exists( $this->filesystem(), $name ) ) { 19 return call_user_func_array( [ $this->filesystem(), $name ], $arguments ); 20 } 21 22 throw new \BadMethodCallException( sprintf( "Method %s does not exist.", esc_html( $name ) ) ); 23 } 8 24 9 25 /** -
groundhogg/tags/4.2.4.2/templates/email/boxed.php
r3343709 r3345192 61 61 </style> 62 62 <style id="block-styles"> 63 <?php echo esc_html( $email->get_css() ) ?> 63 <?php 64 // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped -- esc_html() breaks `div > span` selectors 65 echo wp_strip_all_tags( $email->get_css() ); ?> 64 66 </style> 65 67 <?php do_action( 'groundhogg/templates/email/boxed/head' ); ?> … … 71 73 <table class="alignment-container" style="width: 100%;border-collapse: collapse;" cellpadding="0" cellspacing="0" role="presentation"> 72 74 <tr> 73 <td align="<?php echo esc_attr( $alignment ); ?>" bgcolor="<?php echo esc_attr( $bgColor ); ?>" 74 background="<?php echo esc_url( $bgImage ); ?>" style="<?php echo esc_attr( \Groundhogg\array_to_css( $bodyStyle ) );?>"> 75 <td align="<?php echo esc_attr( $alignment ); ?>" bgcolor="<?php echo esc_attr( $bgColor ); ?>" background="<?php echo esc_url( $bgImage ); ?>" style="<?php echo esc_attr( \Groundhogg\array_to_css( $bodyStyle ) ); ?>"> 75 76 <table class="content-container" cellpadding="0" cellspacing="0" style="border-collapse: collapse" role="presentation"> 76 77 <tr> 77 <td width="<?php echo esc_attr( $email->get_width() ); ?>" 78 style="width: <?php echo esc_attr( $email->get_width() ); ?>px">78 <td width="<?php echo esc_attr( $email->get_width() ); ?>" style="width: <?php echo esc_attr( $email->get_width() ); ?>px"> 79 <?php 79 80 80 <?php load_part( 'browser-view' ); ?> 81 load_part( 'browser-view' ); 82 do_action( 'groundhogg/templates/email/boxed/content/before' ); 81 83 82 <div class="body-content"> 83 <?php 84 do_action( 'groundhogg/templates/email/boxed/content/before' ); 84 // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped -- handled upstream 85 echo $email->get_merged_content(); 85 86 86 // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped -- handled upstream 87 echo $email->get_merged_content(); 88 89 do_action( 'groundhogg/templates/email/boxed/content/after' ); ?> 90 </div> 91 92 <?php load_part( 'footer' ); ?> 87 do_action( 'groundhogg/templates/email/boxed/content/after' ); 88 load_part( 'footer' ); ?> 93 89 </td> 94 90 </tr> -
groundhogg/tags/4.2.4.2/templates/email/full_width.php
r3343709 r3345192 49 49 <meta name="x-apple-disable-message-reformatting"/> 50 50 <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> 51 52 51 <title><?php echo esc_html( $email_title ); ?></title> 53 52 <base target="_blank"> … … 60 59 </style> 61 60 <style id="block-styles"> 62 <?php echo esc_html( $email->get_css() ); ?> 61 <?php 62 // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped -- esc_html() breaks `div > span` selectors 63 echo wp_strip_all_tags( $email->get_css() ); ?> 63 64 </style> 64 65 <?php do_action( 'groundhogg/templates/email/full-width/head' ); ?> -
groundhogg/tags/4.2.4.2/templates/email/full_width_contained.php
r3343709 r3345192 49 49 <meta name="x-apple-disable-message-reformatting"/> 50 50 <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> 51 52 51 <title><?php echo esc_html( $email_title ); ?></title> 53 52 <base target="_blank"> … … 60 59 </style> 61 60 <style id="block-styles"> 62 <?php echo esc_html( $email->get_css() ) ?> 61 <?php 62 // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped -- esc_html() breaks `div > span` selectors 63 echo wp_strip_all_tags( $email->get_css() ); ?> 63 64 </style> 64 65 <?php do_action( 'groundhogg/templates/email/full-width/head' ); ?> … … 67 68 <table class="body-content" cellspacing="0" cellpadding="0" role="presentation" width="100%"> 68 69 <tr> 69 <td bgcolor="<?php echo esc_attr( $bgColor ); ?>" background="<?php echo esc_url( $bgImage ); ?>" 70 style="<?php echo esc_attr( \Groundhogg\array_to_css( $bodyStyle ) ); ?>"> 71 <?php load_part( 'preview-text' ); ?> 72 <?php load_part( 'browser-view' ); ?> 73 <?php do_action( 'groundhogg/templates/email/full-width/content/before' ); ?> 70 <td bgcolor="<?php echo esc_attr( $bgColor ); ?>" background="<?php echo esc_url( $bgImage ); ?>" style="<?php echo esc_attr( \Groundhogg\array_to_css( $bodyStyle ) ); ?>"> 74 71 <?php 72 73 load_part( 'preview-text' ); 74 load_part( 'browser-view' ); 75 do_action( 'groundhogg/templates/email/full-width/content/before' ); 76 75 77 // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped -- handled upstream 76 echo $email->get_merged_content(); ?> 77 <?php do_action( 'groundhogg/templates/email/full-width/content/after' ); ?> 78 <?php if ( ! $email->has_footer_block() ): ?> 78 echo $email->get_merged_content(); 79 80 do_action( 'groundhogg/templates/email/full-width/content/after' ); 81 82 if ( ! $email->has_footer_block() ): ?> 79 83 <table cellspacing="0" cellpadding="0" role="presentation" align="center"> 80 84 <tr> -
groundhogg/tags/4.2.4.2/templates/email/template-functions.php
r3343709 r3345192 1 1 <?php 2 3 use function Groundhogg\files; 2 4 3 5 if ( ! defined( 'ABSPATH' ) ) exit; … … 40 42 41 43 do_action( "groundhogg/templates/email/css/$file" ); 44 $css = files()->get_contents( $file ); 42 45 43 echo esc_html( file_get_contents( $file ) ); 46 // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped -- esc_html() breaks `div > span` selectors 47 echo wp_strip_all_tags( $css ); 44 48 } 45 49 } -
groundhogg/trunk/README.txt
r3344140 r3345192 7 7 Tested up to: 6.8 8 8 Requires PHP: 7.1 9 Stable tag: 4.2.4. 19 Stable tag: 4.2.4.2 10 10 License: GPLv3 11 11 License URI: https://www.gnu.org/licenses/gpl.md … … 374 374 375 375 == Changelog == 376 377 = 4.2.4.2 (2025-08-15) = 378 * TWEAKED Refactored usages of `file_get_contents()` to use the `WP_Filesystem` instead. 379 * FIXED Don't use `esc_html()` for CSS. You'd think WordPress core would have a better internal solution for outputting CSS 🙄 376 380 377 381 = 4.2.4.1 (2025-08-13) = -
groundhogg/trunk/groundhogg.php
r3344140 r3345192 4 4 * Plugin URI: https://www.groundhogg.io/?utm_source=wp-plugins&utm_campaign=plugin-uri&utm_medium=wp-dash 5 5 * Description: CRM and marketing automation for WordPress 6 * Version: 4.2.4. 16 * Version: 4.2.4.2 7 7 * Author: Groundhogg Inc. 8 8 * Author URI: https://www.groundhogg.io/?utm_source=wp-plugins&utm_campaign=author-uri&utm_medium=wp-dash … … 25 25 if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly 26 26 27 define( 'GROUNDHOGG_VERSION', '4.2.4. 1' );28 define( 'GROUNDHOGG_PREVIOUS_STABLE_VERSION', '4.2. 3.1' );27 define( 'GROUNDHOGG_VERSION', '4.2.4.2' ); 28 define( 'GROUNDHOGG_PREVIOUS_STABLE_VERSION', '4.2.4.1' ); 29 29 30 30 define( 'GROUNDHOGG__FILE__', __FILE__ ); -
groundhogg/trunk/includes/bulk-jobs/manager.php
r3343709 r3345192 41 41 } 42 42 43 44 43 /** 45 44 * Magic get method -
groundhogg/trunk/includes/functions.php
r3343709 r3345192 1216 1216 case 'action': 1217 1217 case 'src': 1218 case 'background': 1218 1219 $value = strpos( $value, 'data:image/png;base64,' ) === false ? esc_url( $value ) : esc_attr( $value ); 1219 1220 break; … … 3664 3665 // check the time the file was created, if within our ttl, return the contents 3665 3666 if ( $time && $time > time() - $cache_ttl ) { 3666 $json = json_decode( @file_get_contents( $cached_file ), $as_array );3667 $json = json_decode( files()->get_contents( $cached_file ), $as_array ); 3667 3668 if ( ! empty( $json ) ) { 3668 3669 return $json; … … 3716 3717 // We don't cache errors... 3717 3718 if ( $cache_ttl !== 0 && $cache_key ) { 3718 @file_put_contents( files()->get_uploads_dir( 'requests', $cache_key . '.json', true ),json_encode( $json ) );3719 files()->put( files()->get_uploads_dir( 'requests', $cache_key . '.json', true ), wp_json_encode( $json ) ); 3719 3720 } 3720 3721 … … 4615 4616 function install_gh_cron_file() { 4616 4617 4617 $gh_cron_php = file _get_contents( GROUNDHOGG_PATH . 'gh-cron.txt' );4618 $bytes = file _put_contents( ABSPATH . 'gh-cron.php', $gh_cron_php );4618 $gh_cron_php = files()->get_contents( GROUNDHOGG_PATH . 'gh-cron.txt' ); 4619 $bytes = files()->put_contents( ABSPATH . 'gh-cron.php', $gh_cron_php ); 4619 4620 4620 4621 return (bool) $bytes; … … 4627 4628 */ 4628 4629 function uninstall_gh_cron_file() { 4629 return @unlink( ABSPATH . 'gh-cron.php' );4630 return wp_delete_file( ABSPATH . 'gh-cron.php' ); 4630 4631 } 4631 4632 … … 7395 7396 // initialize providers 7396 7397 if ( empty( $providers ) ) { 7397 $providers = json_decode( file _get_contents( GROUNDHOGG_ASSETS_PATH . 'lib/free-email-providers.json' ), true );7398 $providers = json_decode( files()->get( GROUNDHOGG_ASSETS_PATH . 'lib/free-email-providers.json' ), true ); 7398 7399 } 7399 7400 … … 8829 8830 8830 8831 // Read file content 8831 $content = file _get_contents( $file_path );8832 $content = files()->get_contents( $file_path ); 8832 8833 8833 8834 // Replace occurrences … … 8835 8836 8836 8837 // Write back to file 8837 return file _put_contents( $file_path, $updated_content ) !== false;8838 return files()->put_contents( $file_path, $updated_content ) !== false; 8838 8839 } 8839 8840 … … 9001 9002 function redact_meta_table( $table ) { 9002 9003 9003 global $wpdb;9004 9005 9004 $table = db()->get_db( $table ); 9006 9005 $table_name = $table->table_name; … … 9008 9007 9009 9008 $time = time(); 9010 9011 9009 9012 9010 global $wpdb; -
groundhogg/trunk/includes/utils/files.php
r3343709 r3345192 6 6 7 7 class Files { 8 9 /** 10 * Proxy for filesystem()) 11 * 12 * @param $name 13 * @param $arguments 14 * 15 * @return mixed 16 */ 17 public function __call( $name, $arguments ) { 18 if ( method_exists( $this->filesystem(), $name ) ) { 19 return call_user_func_array( [ $this->filesystem(), $name ], $arguments ); 20 } 21 22 throw new \BadMethodCallException( sprintf( "Method %s does not exist.", esc_html( $name ) ) ); 23 } 8 24 9 25 /** -
groundhogg/trunk/templates/email/boxed.php
r3343709 r3345192 61 61 </style> 62 62 <style id="block-styles"> 63 <?php echo esc_html( $email->get_css() ) ?> 63 <?php 64 // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped -- esc_html() breaks `div > span` selectors 65 echo wp_strip_all_tags( $email->get_css() ); ?> 64 66 </style> 65 67 <?php do_action( 'groundhogg/templates/email/boxed/head' ); ?> … … 71 73 <table class="alignment-container" style="width: 100%;border-collapse: collapse;" cellpadding="0" cellspacing="0" role="presentation"> 72 74 <tr> 73 <td align="<?php echo esc_attr( $alignment ); ?>" bgcolor="<?php echo esc_attr( $bgColor ); ?>" 74 background="<?php echo esc_url( $bgImage ); ?>" style="<?php echo esc_attr( \Groundhogg\array_to_css( $bodyStyle ) );?>"> 75 <td align="<?php echo esc_attr( $alignment ); ?>" bgcolor="<?php echo esc_attr( $bgColor ); ?>" background="<?php echo esc_url( $bgImage ); ?>" style="<?php echo esc_attr( \Groundhogg\array_to_css( $bodyStyle ) ); ?>"> 75 76 <table class="content-container" cellpadding="0" cellspacing="0" style="border-collapse: collapse" role="presentation"> 76 77 <tr> 77 <td width="<?php echo esc_attr( $email->get_width() ); ?>" 78 style="width: <?php echo esc_attr( $email->get_width() ); ?>px">78 <td width="<?php echo esc_attr( $email->get_width() ); ?>" style="width: <?php echo esc_attr( $email->get_width() ); ?>px"> 79 <?php 79 80 80 <?php load_part( 'browser-view' ); ?> 81 load_part( 'browser-view' ); 82 do_action( 'groundhogg/templates/email/boxed/content/before' ); 81 83 82 <div class="body-content"> 83 <?php 84 do_action( 'groundhogg/templates/email/boxed/content/before' ); 84 // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped -- handled upstream 85 echo $email->get_merged_content(); 85 86 86 // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped -- handled upstream 87 echo $email->get_merged_content(); 88 89 do_action( 'groundhogg/templates/email/boxed/content/after' ); ?> 90 </div> 91 92 <?php load_part( 'footer' ); ?> 87 do_action( 'groundhogg/templates/email/boxed/content/after' ); 88 load_part( 'footer' ); ?> 93 89 </td> 94 90 </tr> -
groundhogg/trunk/templates/email/full_width.php
r3343709 r3345192 49 49 <meta name="x-apple-disable-message-reformatting"/> 50 50 <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> 51 52 51 <title><?php echo esc_html( $email_title ); ?></title> 53 52 <base target="_blank"> … … 60 59 </style> 61 60 <style id="block-styles"> 62 <?php echo esc_html( $email->get_css() ); ?> 61 <?php 62 // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped -- esc_html() breaks `div > span` selectors 63 echo wp_strip_all_tags( $email->get_css() ); ?> 63 64 </style> 64 65 <?php do_action( 'groundhogg/templates/email/full-width/head' ); ?> -
groundhogg/trunk/templates/email/full_width_contained.php
r3343709 r3345192 49 49 <meta name="x-apple-disable-message-reformatting"/> 50 50 <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> 51 52 51 <title><?php echo esc_html( $email_title ); ?></title> 53 52 <base target="_blank"> … … 60 59 </style> 61 60 <style id="block-styles"> 62 <?php echo esc_html( $email->get_css() ) ?> 61 <?php 62 // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped -- esc_html() breaks `div > span` selectors 63 echo wp_strip_all_tags( $email->get_css() ); ?> 63 64 </style> 64 65 <?php do_action( 'groundhogg/templates/email/full-width/head' ); ?> … … 67 68 <table class="body-content" cellspacing="0" cellpadding="0" role="presentation" width="100%"> 68 69 <tr> 69 <td bgcolor="<?php echo esc_attr( $bgColor ); ?>" background="<?php echo esc_url( $bgImage ); ?>" 70 style="<?php echo esc_attr( \Groundhogg\array_to_css( $bodyStyle ) ); ?>"> 71 <?php load_part( 'preview-text' ); ?> 72 <?php load_part( 'browser-view' ); ?> 73 <?php do_action( 'groundhogg/templates/email/full-width/content/before' ); ?> 70 <td bgcolor="<?php echo esc_attr( $bgColor ); ?>" background="<?php echo esc_url( $bgImage ); ?>" style="<?php echo esc_attr( \Groundhogg\array_to_css( $bodyStyle ) ); ?>"> 74 71 <?php 72 73 load_part( 'preview-text' ); 74 load_part( 'browser-view' ); 75 do_action( 'groundhogg/templates/email/full-width/content/before' ); 76 75 77 // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped -- handled upstream 76 echo $email->get_merged_content(); ?> 77 <?php do_action( 'groundhogg/templates/email/full-width/content/after' ); ?> 78 <?php if ( ! $email->has_footer_block() ): ?> 78 echo $email->get_merged_content(); 79 80 do_action( 'groundhogg/templates/email/full-width/content/after' ); 81 82 if ( ! $email->has_footer_block() ): ?> 79 83 <table cellspacing="0" cellpadding="0" role="presentation" align="center"> 80 84 <tr> -
groundhogg/trunk/templates/email/template-functions.php
r3343709 r3345192 1 1 <?php 2 3 use function Groundhogg\files; 2 4 3 5 if ( ! defined( 'ABSPATH' ) ) exit; … … 40 42 41 43 do_action( "groundhogg/templates/email/css/$file" ); 44 $css = files()->get_contents( $file ); 42 45 43 echo esc_html( file_get_contents( $file ) ); 46 // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped -- esc_html() breaks `div > span` selectors 47 echo wp_strip_all_tags( $css ); 44 48 } 45 49 }
Note: See TracChangeset
for help on using the changeset viewer.