Viewing 7 posts - 1 through 7 (of 7 total)
  • Author
    Posts
  • #1337305

    Hi,
    we’ve a website running with active maintenance mode.
    Our customer want to have a user that only can read, what technicaly the subscriber role is doing.
    Unfortunately the maintenance mode also effects the reading rule for subscribers.
    We’re wondering if it’s possible to upgrade the subscriber role or creat a new user role that is able to read all pages even if maintenance is active but cant access wd-admin.
    Is this possible? So far we’ve checked the user role attributes with the user role editor and activated “read”, “read_private_pages” and “read_private_posts” attributes. Sadly that had no effect on the maintenance mode and the visibility of the pages.
    Can you provide a solution for this?

    Thanks in advance
    Sebastian

    • This topic was modified 2 years, 2 months ago by emilconsor.
    #1337399

    Hey emilconsor,

    Thank you for the inquiry.

    The capabilities of the user role can be adjusted manually but there is a plugin that should allow you to do this without touching any code. Please check the following plugin.

    // https://wordpress.org/plugins/user-role-editor/

    Best regards,
    Ismael

    #1337427

    Hi Ismael,
    thanks.

    We already use this plugin. Can you tell us which capabilities we should adjust to achieve what we need?

    Best regards
    Sebastian

    #1337468

    Hi,

    Thank you for the update.

    Which maintenance mode plugin are you using? The maintenance mode probably allows user roles with higher capabilities, probably that of an admin which full access to the dashboard, so what you are trying here might not be possible without directly editing the maintenance plugin’s conditions. Unfortunately, that is beyond the scope of support. Please contact the plugin authors for additional info.

    Best regards,
    Ismael

    #1337469

    Hi,

    If you are using the default maintenace mode option in the theme, the user should have the “edit_published_posts” capability, so that might be a problem. You will find this condition in the themes/enfold/includes/class-avia-custom-pages.php file around line 305 inside the handler_maintenance_mode function.

    	if( is_user_logged_in() && current_user_can( 'edit_published_posts' ) )
    			{
    				return $template;
    			}
    

    Best regards,
    Ismael

    #1337476

    Hi Ismael,
    nice, thats it!
    Thanks!

    Regards,
    Sebastian

    #1337761

    Hi Sebastian,

    We are happy that Ismael could help! Let us know if you have any other questions and enjoy your weekend :)

    Best regards,
    Yigit

Viewing 7 posts - 1 through 7 (of 7 total)
  • The topic ‘Disable Maintenance Mode for subscriber or new user role’ is closed to new replies.