Support » Plugins » [Plugin: WP-Wiki] How to restrict “Wiki Editor” capabilities?

  • I’m trying to build a site wiki using the WP-Wiki plugin. (Their homepage, which is not listed there, is at

    It lets you flag certain pages and posts as “Wiki-Editable,” and creates a new type of user called a “Wiki Editor.” Wiki Editors can only edit pages which are marked Wiki-Editable. The problem is, they can also edit all posts, whether those posts are marked Wiki-Editable or not.

    This is not good.

    Here’s the code where it sets up a new capability called ‘edit_wiki’:

    And here’s the new function it creates, which checks for edit_wiki capability before deciding whether or not to allow the user to edit a page:

    I’d like to change it so that Wiki Editors can edit posts (not just pages) which are Wiki-Editable but can’t edit any others. My assumption right now is that I need to comment out more of those granted roles, then write a new function that works like wiki_page_cap except for posts.


    1. Am I on the right track?
    2. How the heck do I do this? I’m almost completely new to PHP and WordPress plugin development.

    Any help would be appreciated. >.>b

  • The topic ‘[Plugin: WP-Wiki] How to restrict “Wiki Editor” capabilities?’ is closed to new replies.