Ask your WordPress questions! Pay money and get answers fast! Comodo Trusted Site Seal
Official PayPal Seal

Limit page edit to specified user(s) WordPress

  • SOLVED

I have a client who wants to set up a sort of business directory on their website, where each business has a page. They want to give the businesses the ability to edit their pages in the directory, but obviously prevent them from editing/deleting/adding any other pages. Therefore, I'm looking for a plugin that allows me to give each user permissions to edit individual pages, and not be able to do anything with any of the others.

I've checked out the Role Scoper plugin, but that was far too complicated for my client.

Answers (2)

2010-10-17

Cosmin Popovici answers:

Why not just let the users sign up and then set Author as the default user role when signing up.

Authors can only edit their own posts, but not others'
They also cannot access any other parts of the admin, such as Appearance or Plugins :)

EDIT:

Thanks :)

You can still use Authors and implement the stuff listed here:
http://www.wphardcore.com/2010/ultimate-guide-to-roles-and-capabilities/

Read this too:

http://www.wprecipes.com/how-to-remove-menus-in-wordpress-dashboard

Best of luck,
Cosmin.


Dan Davies comments:

Authors still have the option to view posts in the dashboard, and add new posts. And also in the case of this website, add new events using the events plugin I have running.

2010-10-17

Denzel Chia answers:

Hi,

How about create new roles and capabilities by using add_roles?
http://codex.wordpress.org/Function_Reference/add_role

Assign the capabilities according to what you want? Capabilities can be found here.
http://codex.wordpress.org/Roles_and_Capabilities

Then use If(current_user_can($capability)) to allow page editing?
http://codex.wordpress.org/Function_Reference/current_user_can

Do a condition check within if current user can function to determine the login user is at their own page before allowing to edit. Which means check capabilty that check if they are on their own directory page.

Thanks.

Edit: somethings wrong here, why am I allowed to post answer, after winner is selected? And question closed? OMG wasted my time.