ダッシュボードから更新の通知を非表示にする
管理者以外にWordPressのアップデートの通知を非表示するコードです。

functions.php
function my_hide_wpupdate() { if (!current_user_can('update_core')) { remove_action( 'admin_notices', 'update_nag', 3 ); } } add_action( 'admin_head', 'my_hide_wpupdate', 1 );

本サイトの内容に誤りや不正確な記述がある場合やサンプルに基づくいかなる結果も一切の責任を負いかねますので、あらかじめご了承ください。