Is it possible to enqueue scripts and css only to the Network Admin Dashboard?
To edit the network admin menu, you have this hook: network_admin_menu
, so I also tried network_admin_enqueue_scripts
, but this didn’t work.
Thanks!
Roc.
Is it possible to enqueue scripts and css only to the Network Admin Dashboard?
To edit the network admin menu, you have this hook: network_admin_menu
, so I also tried network_admin_enqueue_scripts
, but this didn’t work.
Thanks!
Roc.
You must be logged in to post a comment.
You can use the global variable
$current_screen
. It has the propertyis_network
, with a boolean value, that indicates if we are in/wp-admin/network/
or not.This action hook can also be used like
and it will only print in the screen
/wp-admin/network/site-new.php
, so there’s no need to check if the current screen is a network one or not.