Last active
April 28, 2017 15:02
-
-
Save Stiofan/d8f5b5aa3922cfb46928966e75424c11 to your computer and use it in GitHub Desktop.
WP Easy Updates - required notification
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php // <- You probably don't need this line | |
/** | |
* Show WP Easy Updates required admin notification. | |
*/ | |
if(is_admin()){ | |
if (!function_exists('ayecode_show_update_plugin_requirement')) {//only load the update file if needed | |
function ayecode_show_update_plugin_requirement() { | |
if ( !defined( 'WP_EASY_UPDATES_ACTIVE' ) ) { | |
?> | |
<div class="notice notice-warning is-dismissible"> | |
<p> | |
<strong> | |
<?php | |
echo sprintf( __( 'The plugin %sWP Easy Updates%s is required to check for and update some installed plugins/themes, please install it now.', 'geodirectory' ), '<a href="https://wpeasyupdates.com/" target="_blank" title="WP Easy Updates">', '</a>' ); | |
?> | |
</strong> | |
</p> | |
</div> | |
<?php | |
} | |
} | |
add_action( 'admin_notices', 'ayecode_show_update_plugin_requirement' ); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment