1

We have a number of sites that use WordPress Multsite and over the last couple of months we have noticed that we now cannot access the main WPMS Dashboard any longer where the plugins are added, users are updated or themes are enabled.

Here's what we have tried.

  • backed up htaccess and WP config files.
  • renamed htaccess by adding a dash at the end of the file name (.htaccess-)
  • setting the WPMS settings to false
/* Multisite */
define( 'WP_ALLOW_MULTISITE', false );
define('MULTISITE', false);
  • Updated all the plugins
  • Updated Core
  • Reversed all the work done
  • Still the same result

I have Googled and read through all the options related to my search but none of the options I have found to have worked

Any thoughts? Thanks

EDIT

After doing some research, it would seem that the Super Admin accounts have somehow changed to normal WordPress admin accounts.

Are there any known changes in the latest WordPress updates that might have caused this? We would like to get to the bottom of it and prevent it from happening again.

1 Answer 1

2

You can gain super admin access to the site by adding this function in the functions.php file

if ( !function_exists( 'grant_super_admin' ) ) { 
    require_once ABSPATH . WPINC . '/capabilities.php'; 
} 
  
// ID of the user to be granted Super Admin privileges. 
$user_id = 1; 
  
$result = grant_super_admin($user_id); 

You can remove the code once you have access, although I'm not sure why the user was changed to Administrator

1
  • Excellent, thank you!
    – Grow
    Aug 4, 2021 at 10:53

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.