Directory User Permissions

I got the directory plugin setup and I am not able to properly configure permissions. I just want a user (e.g. directory not paid) to be able to View, Add, Edit, Delete ONLY their listings & not any others in the directory, they should also be able to upload a featured image (but not be able to view or edit any other media files). I'm assuming that this is the most basic, logical & popular configuration but I can not find a combination of permissions that will allow this to work. What do I do ? Thanks ! (my url is http://67.227.244.194/~onlineth/)

  • Patrick
    • Support Monkey

    Hiya @tzvimoshe,

    I've been fiddling with Directory settings on a virgin test install (localhost) for the last 45 minutes, and it would appear that there is a problem with the "Add Listing" capability in this version.

    To set things up the way you have described them above, subscribers should have the capabilities as seen in the attached screenshot. Also, be sure you have assigned that role as the member's role, and that directory status options is set at least to "Publish". Finally, be sure the payment type is set to free listings.

    I'm going to alert the plugin developer to possible issues with this version of the plugin to see what insight he may have.

    Hope this helps! And thanks for being a member :slight_smile:

  • Arnold
    • El Macho WP

    If you want to enter free listings as described above you need to set Payment Type to Free. Then on the Role you want to be able to do this you need to set Add Listings, Edit Listings, Edit Published Listings, Delete Listings, Delete Published Listings, and Upload Files.

    Normally you ignore Private listings unless you're the Admin because there's no way to add a password to the listing except through the back end. For Other's listings we don't implenent that any way except for the usual Administrator or Editor.

    Upload Files turns on or of the Featured images. They are automatically restricted to the Users media. Don't confuse yourself by being logged in as admin and wondering why you can see everything.

    If you looking to only allow feature images and not allow embedded media in the post or any other media, you'll have to do some custom programming because Wordpress doesn't support that directly.
    post

  • tzvimoshe
    • Flash Drive

    Thanks for all the support !!!

    Patrick; I tried your way but that wouldn't allow me to view listings from admin at all.

    Joe; Yes I am

    Arnold; Thanks for your comprehensive response. Almost everything is working.

    except:

    1) I setup the permissions for "directory member not paid" as stated by Arnold with Add Listings, Edit Listings, Edit Published Listings, Delete Listings, Delete Published Listings, and Upload Files. However, when logged in as that user, I am able to view listings from other members in the admin screen. Although I can't edit or delete them, I still think its just confusing and unprofessional for one user to see other members listings in their listings dashboard.
    2) I have set the default role in "Assign Member's Role" to "directory member not paid", however when I create a new account from the signup page it gives them the subscriber role ?

  • Arnold
    • El Macho WP

    1) I'm confused. Isn't the whole purpose of posting listings is so other people can see them?? If I use unmodifed Wordpress and set a users role as "contributor", which is the minimum to allow entry of posts, I can still see everybody else's posts, I just can only enter my own.posts. Can;t touch the others.

    So Wordpress standard vanilla function is exactly what you've got.

    If you want to do that kind of thing. Here's the basics. You would have to make sure it covers custom types as well.

    http://blog.rutwick.com/display-only-the-posts-authored-by-the-current-wp-user-on-the-posts-page-in-the-back-end

    2) This is just basic Wordpress. The default role on signup is defined in the Settings > General > New User Default Role.

    Note you have to have use a plugin of somesort to do this on Multisite because they only signup a user to the primary site (usualy 1) On other sites you have no rights at all until specifically assigned. No role means you can't do anything on the site. So you need to oredefine it when the blog is created. This might work but it's kind of old.

    http://wordpress.org/extend/plugins/new-blog-default-user-role/

    The Assign Member's Role in Directory is the role assigned when they actually buy something from Directory. That makes you a Directory member but you have to register as a user before you can get to the buy stuff.

    Your using free so this wouldn't normally occur so your capabilites should be set for the registration default.

  • timbryden
    • Flash Drive

    Finally some kind of clarification.

    It appears to me that some documentation around what the intention for the two additional roles actually is would be useful. It's very frustrating. The assumption seems to be we've used other similar plugins.

  • timbryden
    • Flash Drive

    I think the following would be useful:

    Directory - Role and Capabilities - Example Setups for Vanilla wordpress.

    1. Directory for free listings only.
    2. Directory for 1 free listing only.
    3. Directory for free signup and creation of 1 draft listing, but paid for 1 published listing.
    4. Directory for paid listings only.
    5. Directory for 1 paid listing only.
    6. Directory for 1 free listing but paid for additional listings.

    I'm sure there are other combinations but the above (or a subset of these) would be very useful.

  • tzvimoshe
    • Flash Drive

    Good point I was wondering that myself, how can I set the permissions so that a user can only create one listing? I don't want user creating more than one listing. I guess you can just change the user's role after the first listing is created, but is there an easier way ?

  • Arnold
    • El Macho WP

    If you want to give 1 free directory listing.

    In Payment Type uncheck everything.

    In Payment check Credit, Set Credits per listing to 1 Credit and set Signup credits to 1

    Set your subscriber with the usual capabilities

    Then when a user registers they have the capabilities, get 1 credit for signing up so they can post one listing, but they can't buy anymore credits.

    .

  • timbryden
    • Flash Drive

    That makes sense... except for quite a while I thought the Directory specific roles needed to be used. I have since reworked things... as I do want a mix of payment, free and try before you buy.

    My point above is simply that clarification in the documentation with a couple of examples would save lots of frustration.

  • Arnold
    • El Macho WP

    They were in the old version. Problem was if you ran both Directory and Classifeds on the same site, a user can only have One role. So you could be directory or classifeds but not both. Done the new way you can use the same arbitrary role name for both and set the capabilities for each separately

  • tzvimoshe
    • Flash Drive

    I just tried it now thank you. Actually that solution is great for one free listing. However I want to charge $30 per month to have one listing. I need to use the recurring payments mode. So how can I set it that user is only allowed one listing? Thanks !

  • Arnold
    • El Macho WP

    That would have nothing to do with capabilities. You're asking for "if this user expires, take away the rights for everyone else to see his listings."

    To do that you need some other mechanism. Simplest is to set their post status to "private" and remove the capability to edit private listings. And a different way of buying the service.

    I'd use the Membership plugin for payment and subscription and use a filter to decide whether the user is still subscribed and change the status on their listigns if not. to published or private depending.

    Now though your getting into custom programming.

  • tzvimoshe
    • Flash Drive

    No I don't mean ""if this user expires, take away the rights for everyone else to see his listings." Rather I want that every person who wants to have a listing on my website should have to pay a monthly fee to do so, AND only be allowed to create one listing. I don't want a paid directory member to create 10 listings when they are only entitled to one. Ho to ?

  • Arnold
    • El Macho WP

    I understand. What I gave before will do that. But now you have to enforce the payment by a different mechanism. It's no longer just buying Listigns but buying a Listing and something must happen if they don't pay. That's the hiding the Listigns for everyone else if he doesn't pay. Membrship would be used to turn on and off the viewing of their 1 Listings depending on whether the are paid up or not.

  • Arnold
    • El Macho WP

    Exactly the same way as described above. Give them the one credit on free registering but don't give them the capability. Then when they pay through Membership change their role to one with the capability. The can now enter ther listing. But they've used their credit so they can't enter more. Then another piece of code watches their membership status and changes the status on their listing if they expire the subscription. If they pick up the payment you turn it back on.

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.