Redirect Non-Admin Users from the Backend of WP

Redirect Non-Admin Users from the Backend of WP

Here’s a little piece of code that keeps users away from the backend of WordPress.  Let’s say you have built a profile system from the frontend and you only want users to manage these settings through your interface.

 

You can customize this even further by changing the permission(current_user_can) parameter, if you only want admin and editors to access the backend.

No Comments

Post A Comment