Viewing 10 replies - 16 through 25 (of 25 total)
  • SFGolfer I’m not sure if this will be helpful, but I also admin a network of “non technical” users. Being that they are already non-technical I simply went the direction of hiding elements using CSS. I wrote up a plugin and that is one of it’s functions; load custom CSS based on user role. This gives me total control of what they see and can access.

    function load_custom_wp_admin_style()
    		{
    			echo '<link href="https://urltoyourstylesheet-1" rel="stylesheet" type="text/css">';
    
    				if (is_super_admin(1 == $current_user->ID))
    				{
    					echo '<link href="https://urltoyourstylesheet-2" rel="stylesheet" type="text/css">';
    					}
    
    				else
    				{
    					echo '<link href="https://urltoyourstylesheet-3" rel="stylesheet" type="text/css">';
    
    				}
    		}

    I basically load a default stylesheet for everyone, then a special stylesheet for me, or none if you like, and lastly a stylesheet for everyone else.

    I did just this for Shortcodes Ultimate.

    a.su-generator-button {
      display:none !important;
    }

    Plugin Author Vova

    (@gn_themes)

    I’ll try to work something out in closest versions.

    Plugin Author Vova

    (@gn_themes)

    You can add next line of code to your theme’s functions.php

    update_option( 'su_generator_access', 'administrator' );

    It will start working from next version (4.1.1).

    The update_option did not work.

    What does this snippet do?

    What do I put in there to prevent the Author role from accessing SU?

    Plugin Author Vova

    (@gn_themes)

    Did you updated to 4.1.1?
    Where do you paste this snippet?
    Try to replace administrator with editor. This value defines minimal user role to access the generator.

    Yes, I did update to 4.1.1 but did not see an option to set the level.

    But changing it to editor worked. Now I understand it defines the minimal user level.

    Thank you!

    @jarmerson – thanks for your input as well. I’ll probably use your code for another purpose.

    Plugin Author Vova

    (@gn_themes)

    Yes, I did update to 4.1.1 but did not see an option to set the level.

    I think there is no need to overload settings page with options like this one.

    Plugin Author Vova

    (@gn_themes)

    Thank you for review =)
    Just created article about this hack – https://gndev.info/kb/how-to-restrict-access-to-shortcode-generator/

    Hi,
    Sorry for my bad english. I’ve got a problem with galleries utilization: administrators can manage galleries but what about other roles ?
    I need my authors or editors to be able to create galleries in order to put them into their posts. But when an author clicks onto “manage galleries”, a message appears saying that they “do not have sufficient permissions to access this page”. I think it’s because they don’t have access to plugins therefore they can’t access to the tab of “Shortcode Ultimate” that allows to manage galleries. How can I solve this problem?
    Your plugin is awesome, beautiful and really easy to use and I don’t want to be obliged to create everyday each gallerie for each post. Thanks a lot for your answer !

    I need non-admins but users with edit-posts capabilities to edit Galleries also. Please fix it. Thank you

Viewing 10 replies - 16 through 25 (of 25 total)
  • The topic ‘Non-Administrators "Access Denied"’ is closed to new replies.