Skip to content

Instantly share code, notes, and snippets.

@Pebblo
Last active August 1, 2019 12:51
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Pebblo/205b500c0c33f7583cdc7f08c89800e9 to your computer and use it in GitHub Desktop.
Save Pebblo/205b500c0c33f7583cdc7f08c89800e9 to your computer and use it in GitHub Desktop.
Example of how to change the EE admin foot text to include details from other plugins. #EE #admin_general
<?php //Please do not include the opening PHP tag if you already have one.
//Remove the EE espresso_admin_footer callback and add another which includes current content.
add_action('admin_init', 'tw_filter_admin_footer_text');
function tw_filter_admin_footer_text() {
$admin = EE_Registry::instance()->load_core('EE_Admin');
remove_filter('admin_footer_text', array($admin, 'espresso_admin_footer'));
add_filter('admin_footer_text', 'tw_ee_filter_powered_by_event_espresso');
}
function tw_ee_filter_powered_by_event_espresso($content = '')
{
$powered_by_event_espresso = \EEH_Template::powered_by_event_espresso('aln-cntr', '', array('utm_content' => 'admin_footer'));
return $content ? $powered_by_event_espresso . '<br/>' . $content : $powered_by_event_espresso;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment