Skip to content

Instantly share code, notes, and snippets.

@nerrad
Created March 18, 2014 23:08
Show Gist options
  • Save nerrad/9631766 to your computer and use it in GitHub Desktop.
Save nerrad/9631766 to your computer and use it in GitHub Desktop.
using new messages css file filters
<?php
function ee_inline_css_swap( $path_or_url, $type ) {
$upload_dir = wp_upload_dir();
if ( $type == 'preview' ) {
$path_or_url = $upload_dir['baseurl'] . '/email-messenger-inline-preview-css.template.css';
} elseif ( $type === FALSE ) {
$path_or_url = $upload_dir['basedir'] . '/email-messenger-inline-css.template.css';
}
return $path_or_url;
}
add_filter( 'FHEE__EE_Email_Messenger__get_inline_css_template__css_url', 'ee_inline_css_swap', 10, 2 );
add_filter( 'FHEE__EE_Email_Messenger__get_inline_css_template__css_path', 'ee_inline_css_swap', 10, 2 );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment