PriMoThemes — now s2Member® (official notice)

This is now a very OLD forum system. It's in READ-ONLY mode.
All community interaction now occurs at WP Sharks™. See: new forums @ WP Sharks™

Can my members have AUTHOR capability?

s2Member Plugin. A Membership plugin for WordPress®.

Can my members have AUTHOR capability?

Postby scottfennell » January 25th, 2012, 4:44 pm

Hi,

I just installed and configured this great plugin. I think it will be a great solution, but I'm stuck on one thing.

When users register for my site, I need them to have the Wordpress AUTHOR capability (they need to be able to post in two different custom post types, edit their own posts, delete their own posts, and of course edit theire profile).

I'm just not seeing how to do this.

Currently, all they are able to do is edit their profile. S2 "takes control" of wp-admin-->general settings-->new default user role, setting it to SUBSCRIBER, when I need it to be AUTHOR.

This is what I've attempted so far (in my theme-->functions.php):

Code: Select all
add_action('admin_init', 'empower_users');
function empower_users()
{
$role = get_role( 's2member_level4' );

$role->add_cap( 'pubish_post' );
$role->add_cap( 'edit_post' );
}


It doesn't work; it doens't appear to do anything.
User avatar
scottfennell
Registered User
Registered User
 
Posts: 3
Joined: January 25, 2012

Re: Can my members have AUTHOR capability?

Postby scottfennell » January 26th, 2012, 12:15 pm

Well, I was able to edit the roles using the User Role Editor plugin.

I'm not sure what I was doing wrong with my code above.

It's really quite silly that S2member spends so much time belaboring the point about different user levels (I spent an hour watching videos on the topic yesterday), only to give no native way for me to edit their admin capabilites (post, edit, delete, upload, etc).

Why not include this?
User avatar
scottfennell
Registered User
Registered User
 
Posts: 3
Joined: January 25, 2012

Re: Can my members have AUTHOR capability?

Postby Cristián Lávaque » January 26th, 2012, 6:12 pm

Hi Scott.

s2Member only manages user access to the content on the front end, it doesn't manage the back end of WP at all. There are different reasons why we didn't choose to add this yet, and it isn't promoted as such.

That said, when someone asks how to do that, we usually tell them they can edit the user roles with User Role Editor like you did, but that's the site owner's responsibility to customize and make sure it doesn't have security problems.

Maybe we should make a clear statement about s2Member not managing access to the admin area. Thanks a lot for pointing it out. :)
Cristián Lávaque http://s2member.net
Is s2Member working for you? Please rate it Image at WordPress.org. Thanks! :)
User avatar
Cristián Lávaque
Developer
Developer
 
Posts: 6836
Joined: December 22, 2010

Re: Can my members have AUTHOR capability?

Postby scottfennell » January 26th, 2012, 6:30 pm

I think that would be appropriate. Thanks for the response.
User avatar
scottfennell
Registered User
Registered User
 
Posts: 3
Joined: January 25, 2012


Return to s2Member Plugin

Who is online

Users browsing this forum: Yahoo [Bot] and 1 guest

cron