Getting a user role from the user login name
The question might be simple. Since I need to fix it soon I had to ask.
The question might be simple. Since I need to fix it soon I had to ask.
I have created a custom role called Custom Author. Users in this role can edit their own pages and add new pages. I would like to restrict new page creation and allow Custom Authors to create pages only as child pages of their own pages. In other words, I would like them to still be able to create new pages, but only as child pages of the pages they have editor access to.
I use a plugin called “Live Edit” to let authors and editors edit the content front-end. But the issue is that the plugin lets any logged in users to edit the content. I want the edit(specified by plugin. Not the WP’s default edit button) button be accessed based on their roles. I don’t know how to make it accessible based on roles. So trying to make it appear only for the authors and higher roles to that.
I need to create one admin account for seo editer. This user only edit seo fields in Product edit form
and category edit form
I added a new user which has ALL rights. However, he can’t open the site in admin under
I would like to assign role to users on registration from my module.
I need to restrict users from editing custom post types that don’t have a taxonomy or custom meta value matching a hidden value in their WP user meta.
The Objective:
Create a custom post type and only give administrator and a custom role permission to view / control it.
My plugin have minimum configuration like below.I can see plugin via WP admin under woocommerce main menu.but cannot see plugin from different role.That role can see woocommerce submenu.Only my custom submenu link not visible.
I created a custom post type (“Organization”), and I’ve also created a custom user role (“Representative”). Also, I’ve ensured that the Representative role has read/edit/create/publish post capabilities.