Restrict access to specific widget field based on user role
I ended up adding the class ‘ab-ads’ to all my widget areas. if ( !is_super_admin() ) { add_action(‘admin_print_styles-widgets.php’, function() { echo ‘<style type=”text/css”>div.sidebar-widgets-ab-ads { display:none; }</style>’; }); } That way I just hide them for everyone that isn’t administrators.