A
A
Alexander K2015-11-06 15:33:52
CMS
Alexander K, 2015-11-06 15:33:52

How to completely disable the wordpress console for subscribers?

Good day to all.
Making a blog site for one project on cms wordpress, I ran into one very significant problem. As it turned out, the console (wp admin panel) is available to all users by default and there is no function in the admin panel to disable it for subscribers. I began to google and sort through a bunch of plugins but to no avail.
Please suggest any plugin that solves this problem. I need for the subscriber to edit the profile and other interactions with the profile and account be within the front-end zone without an admin panel.

Answer the question

In order to leave comments, you need to log in

4 answer(s)
I
Igor Vorotnev, 2015-11-07
@privetizkosmosa

Out of the box, WP provides limited access to the admin area. But there are a lot of plugins that implement profiles / personal accounts on the frontend, in the design of the site. I googled for you .

L
Leonid, 2017-06-15
@easycode

Maybe someone else will come in handy. Solving the issue of blocking access to the WordPress admin panel for users with the role: subscriber ( subscriber ):

add_action('admin_init', function() {
  if (current_user_can('subscriber')) {
      wp_redirect(site_url());
      die();
  }
});

no plugins or anything, just a little code that solves the problem.
upd.: I corrected the code - it can be inserted into functions.php for example

S
Super User, 2015-11-06
@sergeystepanov1988

Put this code in functions.php and no plugin needed:

if ( current_user_can( 'subscriber' ) ) {
    show_admin_bar( false );
}

In general, it is disabled for specific users by simply unchecking the "Show the top bar when browsing the site" checkbox.

@
@erstet, 2015-11-06
_

I'm sorry for the offtopic, it became wildly interesting how to display tapas (red circles and other selections) of a visitor who came through the phone or just on the sensor as on max-3000 cms? I really want to try something like this)

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question