Irfantony
(Irfan Tony)
August 16, 2021, 10:09am
1
Hi,
Is there an easy way to suppress all notifications in the MainWP dashboard?
https://share.getcloudapp.com/4gulxG8E
We already have these notifications on the WP dashboard, no need to have them show up again on the MainWP dashboard. It also creates confusion for my VA.
Thanks
rhoekman
(Rick Hoekman)
August 16, 2021, 3:29pm
2
Just wondering what VA means?
bogdan
(Bogdan Rapaić)
August 16, 2021, 3:54pm
3
Basically, the notices that show in the area that you showed in your screenshot are notices that are hooked into the admin_notices
WP default hook.
If you want to hide them, you can use the following command to unset the whole hook:
remove_all_actions( 'admin_notices' );
You can find more details here .
2 Likes
bogdan
(Bogdan Rapaić)
August 16, 2021, 3:55pm
4
If I am correct, it should be Virtual Assistant
3 Likes
Irfantony
(Irfan Tony)
August 19, 2021, 7:58am
5
Thanks @bogdan
It’s works.
I’m using this:
if (!is_admin()) {
remove_all_actions( ‘admin_notices’ );
Yeah, VA = virtual assistant
1 Like
josklever
(Jos Klever)
August 19, 2021, 10:52am
6
!is_admin()
means that this will be executed in the frontend of the website, because is_admin()
will test if the WP backend (dashboard) is loaded. And don’t forget to close the if statement with }
1 Like
system
(system)
Closed
August 20, 2021, 10:53am
7
This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.