I would agree that current_user_can(‘Administrator’) should return true for the user. However, current_user_can is primarily intended to check for capabilities, which is generally a more robust check to be making.
I’d suggest something like this (untested):
if ( current_user_can( 'activate_plugins' ) && ! current_user_can( 'update_core' ) ) {
//...
}
So this is checking if the current user can activate plugins but cannot update core. This should return true for Administrators whilst returning false for Network Admins – as on multisite update_core is reserved for Network Admins.
Related Posts:
- Add WordPress MU Network Admin via Database
- How Can I Centralize Content Usage and Approval in a WordPress Multi-Site installation
- WordPress Multisite allow site admin to add user without email confirmation
- How to hide admin account in BuddyPress? (for security reasons)
- Restrict Admin Capabilities in MultiSite
- How to add super admin to all sites
- Uploading Images to Multi-Site Causes Failure to HTTP Error
- ID’s being stripped out of editor for Admin user in Multi-Site
- How to add multiple existing users to a multisite site?
- Can I manage more wordpress sites with one wordpress administrator page? [closed]
- Add menu page on multisite
- Why is my multisite installation not showing all the available sites?
- How to get the site administrator/s by blog id
- PHP Notices appear when browsing any page in admin, but only for child theme, using code from WP Codex
- Restrict Admin Capabilities in MultiSite
- current_user_can() always returns true if user is super admin
- Display site administrator’s id by current blog id inside link
- Unable to apply theme to WordPress Network Site install
- Four columns in the wp_users table
- WordPress Multisite dashboards redirect to homepage
- Limit entries number on network/sites.php
- Multisite User cannot access dashboard
- InfiiniteWP and WP Networks (multisite)
- Site’s admin created with wpmu_create_blog accessible only on 2nd attempt
- Where to set individual blog quotas?
- How do I check if the user is a site owner in a network?
- how to have __() translating in languages different from admin?
- MultiSite: new Sites not showing up
- Is There A Plugin to Create WP Multisite Installs programatically
- WordPress multisite, allow non super admins to create sites
- Function to Load Admin CSS for Super Admin on Multisite
- Admin users not able to see network menus
- Hook into ‘admin_url’ but only on Mysites admin bar menu
- WordPress Multisite FQDN Admin Access
- Delete all blogs on multisite
- How to create 30 new sites from an export of a master site?
- Pages redirect me to the homepage
- Not an admin on a multisite setup but I want to change the fonts
- Can admins on network install view and edit users accounts?
- List all blogs a user can admin [duplicate]
- Site admin in a network install can’t edit users?
- Multisite – sub-subfolders for certain blogs
- Multisite behind Varnish
- How do I know if a user has a blog in WordPress Multisite?
- How does WordPress connect sites and the wp_users table?
- How to migrate WordPress Blogs into Multisite without using the GUI-Import/Export Feature
- WordPress network (multisite) /wp-admin/ redirect loop (ERR_TOO_MANY_REDIRECTS)
- Suppress subdirectory from WordPress Multisite primary URL
- Has anyone experience w/ WordPress (MultiSite) hidden users (possibly hacked)?
- Why wordpress multisite redirect to wp-signup if site exists?
- Subdirectory multisite installation with several domain names?
- Can’t access WordPress multisite after connecting to domain
- In MultiSite, can some users automatically have Site Admin rights on all sites, without granting them Network Admin access?
- create_users capabilities on a role on multisite
- Domain name in a WordPress Network
- How to change user starting role in WordPress MultiSite?
- Multi-Site Subdomain: Show master site under subdomain if no sub site exists
- Register existing user on another site in a multisite network?
- Can i import a site (plugins, database, images) etc. Into an existing wordpress multisite?
- Importing XML didn’t finish, site is now inaccessible
- WordPress multisite – Bitnami
- One blog inside another
- Change Default WordPress MU Blog
- wordpress multisite permalink structure: mostly subdomains but not all
- Bulk Move Users from one site to another within a network ( Multisite )
- Multisite – getting a 404 for additional site created using subdomain install
- muliple wordpress multisite installs on the same sever
- how to create wordpress network with multiple wordpress installations
- get_last_updated() not working – multisite loop
- Multiple sites with independent users
- Programmatically creating site in a network
- What happens when someone goes to the root URL in WordPress Multisite?
- Migrate single site to Multisites with plugins, cPanel and already working subdomains
- how to install wordpress HyperDB
- Multisite Redirect for Home Page Only
- 404 not working on main site on multisite
- add_blog_option blog ID
- Cannot see dropdown shortcut to site dashboard in WordPress network why?
- How can I install WordPress as blog provider , stable?
- Automatic creation of mutisite blog outside of the admin
- List all sites created in network and get the language used for each site
- Automatically add a registered user on the wordpress multisite network even to just one other site
- Redirecting specific sites to HTTP in WordPress Multisite
- WordPress Multisite VMware copy for dev use not allowing loggin
- Multisite,half the way
- Create new multisite from existing and keep domain?
- WordPress Multisite: Login to all subsites at once
- WordPress Multisite: an official and definitive way to enable https ? (http to https)
- Synchronize wordpress site between two different servers
- What dictates whether a plugin will be available to a site in a multisite install?
- How do I setup WordPress Multisite in it’s own directory?
- Configuring Multisite with subdomains
- How do I remove ‘www.’ from all internal links in self-hosted multisite?
- How do I make a copy of WordPress to other folder
- MU Domain mapping
- WordPress multisite with subdirectories always redirects to mainsite
- Can i use the same content in two websites? one is the main website and one is directory website
- Single installation with sub-domains for admin and separate domains for sites
- The wpmu_blogs_columns filter is not working
- Map WP Multisite blog.example.com to anotherdomain.com/blog?