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™

categories subscriptions/bundles

s2Member Plugin. A Membership plugin for WordPress®.

categories subscriptions/bundles

Postby syadasti » May 26th, 2010, 9:12 am

Hello Jason,

s2member looks like a fantastic piece of software for some use cases. I'm trying to figure out if mine is (or will be) supported.

I run a news site where we want to introduced category-based premium content (energy industry news, business news, public tenders, etc.). Ideally, I'd like to be able to offer each category as a standalone subscription, with bundling options as well.

It appears that the membership levels concept, though, is cumulative. So, I could have "bronze" give access to business news and public tenders, but then "silver" would give access to the bronze categories plus energy industry news. And this leads me to believe that what I describe above isn't possible. Or is it?
User avatar
syadasti
Registered User
Registered User
 
Posts: 4
Joined: May 26, 2010

Re: categories subscriptions/bundles

Postby Jason Caldwell » June 23rd, 2010, 11:44 pm

Very sorry, my for extremely delayed response.

s2Member can be extended well beyond the default Levels [0-4].
But first, I should explain that the concept of "Levels" are really NOT that powerful all on their own. Don't get me wrong, they work wonders in lots of cases, and they're really simple to work with. However, they're not easily extended for complex situations, and thus, have become an outdated way of handling on-site permissions that require lots of complexity.

In other words, even if we designed s2Member to support up to 100 Levels, or even unlimited, that still would not resolve common problems ( limitations ) associated with Levels.

The best way to extend s2Member is through the application of Custom Capabilities.
Please see s2Member's section on Custom Capabilities under:
s2Member -> API / Scripting -> Custom Capability Packages.

Using Custom Capabilities, you can apply special permissions for different packages, while using just ONE, or possibly TWO of s2Member's built-in Levels. This is the same concept that WordPress® Roles/Capabilities are based on, and is the main reason why the concept of Levels is slowly being deprecated.
~ Jason Caldwell / Lead Developer
& Zeitgeist Movie Advocate: http://www.zeitgeistmovie.com/

Is the s2Member plugin working for you? Please rate s2Member at WordPress.org.
You'll need a WordPress.org account ( comes in handy ). Then rate s2Member here Image
.
User avatar
Jason Caldwell
Lead Developer
Lead Developer
 
Posts: 4045
Joined: May 3, 2010
Location: Georgia / USA

Re: categories subscriptions/bundles

Postby syadasti » June 23rd, 2010, 11:59 pm

Hey Jason, no apology required, actually this is the second-best news I got all day :)

Are you aware of any implementations of something like what I describe, based on custom capabilities? I'm happy to do my own coding if need, but maybe you know of something out there already.

Thanks!
User avatar
syadasti
Registered User
Registered User
 
Posts: 4
Joined: May 26, 2010

Re: categories subscriptions/bundles

Postby Jason Caldwell » June 24th, 2010, 12:15 am

s2Member is probably the best option. I would use s2Member, in conjunction with the Capability Manager plugin; giving you fine grain control over all Custom Capabilities.
http://wordpress.org/extend/plugins/capsman/

Don't forget the primer on Custom Capabilities, under:
s2Member -> API Scripting -> Custom Capabilities.

That being said, you can further avoid some scripting, by packaging default Custom Capabilities into the s2Member Levels [0-5]. Where 0 = Free Subscriber. There again though, using the Capability Manager, you could change all of this to whatever you need.
~ Jason Caldwell / Lead Developer
& Zeitgeist Movie Advocate: http://www.zeitgeistmovie.com/

Is the s2Member plugin working for you? Please rate s2Member at WordPress.org.
You'll need a WordPress.org account ( comes in handy ). Then rate s2Member here Image
.
User avatar
Jason Caldwell
Lead Developer
Lead Developer
 
Posts: 4045
Joined: May 3, 2010
Location: Georgia / USA

Re: categories subscriptions/bundles

Postby DigitalDon » June 27th, 2010, 1:01 pm

Another possible solution - although it would be a complex one - might be to install Dolphin Community Builder, an Open-Source community platform produced by Australian-based Boonex Pty. Ltd.

Dolphin might be "overkill" for what you appear to want to do, but on the other hand it may be the sort of platform that would lend itself well to customizing each individual membership's access capabilities in the manner you're describing. It also integrates with AlertPay as well as PayPal, and has many built-in modules which can be activated or de-activated depending on what you wish to offer your members.

(It should be noted that Dolphin requires you have a server with a dedicated IP address or at minimum a Virtual Private Server in order for many of the multimedia modules such as video and audio sharing to function.)

Complete information can be found at http://www.Boonex.com/Dolphin

Of course I don't wish to disparage s2Member in any way, shape, or form, as it appears to be very well-assembled, and the attention and support Jason provides is a clear indicator of his professionalism (something that's sadly lacking in most online businesses these days).

Best regards for a successful commercial membership enterprise!

- "Digital" Don Hill -
Co-host - Google Me Talk Radio
DigitalDon
Guest User
Guest User
 

Re: categories subscriptions/bundles

Postby syadasti » June 28th, 2010, 1:52 pm

Thanks for the guidance, Jason. At least in my sandbox, I've now demonstrated that the capability-based approach works brilliantly.

Code: Select all
global $current_user, $post;
get_currentuserinfo();
if ($current_user->user_level > 1) {
  the_content('<p class="serif">Read more</p>');
} else if (is_user_logged_in() && current_user_can("access_s2member_level1")) {
  if ((in_category("music") && current_user_can("access_s2member_ccap_music")) ||
      (in_category("tenders") && current_user_can("access_s2member_ccap_tenders"))) {
    the_content('<p class="serif">Read more</p>');
  } else {
    echo "<p>" . $post->post_excerpt . "</p>";
    echo "<p>Restricted1.</p>";
  }
} else {
  echo "<p>" . $post->post_excerpt . "</p>";
  echo "<p>Restricted2.</p>";
}
?>


Basically, if the user is "contributor" or greater, display content. If not, if logged in and >= level1, if allowed to see the category, show the content. Otherwise, show the excerpt and invite them to subscribe.

Thanks!
User avatar
syadasti
Registered User
Registered User
 
Posts: 4
Joined: May 26, 2010

Re: categories subscriptions/bundles

Postby Jason Caldwell » June 29th, 2010, 12:49 am

Thank you VERY much for the followup.

Watch out using $current_user->user_level
That is NOT the s2Member Level. It's a deprecated WP level, no longer used.

$current_user->user_level = the WordPress level, NOT the same thing as the s2Member Level.
$current_user->user_level is part of the WP core, and it's deprecated as of WP 2.8.
- that property will eventually be removed completely, in favor of capabilities.

So, if what you're really asking is.... Does the Member have an s2Member Level > 1, you would do this:
Code: Select all
if(current_user_can("access_s2member_level2"))
    {
         // Yes, the Member can at least access Levels 2, 1, and 0.
    }

Or this:
Code: Select all
if(S2MEMBER_CURRENT_USER_ACCESS_LEVEL > 1)
    {
        // Yes, the Member can at least access Levels 2, 1, and 0.
    }

I know you already know this, but I'm tagging this on for anyone else reading this.

Membership Levels provide incremental access:

* A Member with Level 4 access, will also be able to access Levels 0, 1, 2 & 3.
* A Member with Level 3 access, will also be able to access Levels 0, 1 & 2.
* A Member with Level 2 access, will also be able to access Levels 0 & 1.
* A Member with Level 1 access, will also be able to access Level 0.
* A Subscriber with Level 0 access, will ONLY be able to access Level 0.

* WordPress® Subscribers are at Membership Level 0. If you're allowing Open Registration, Subscribers will be at Level 0 ( a Free Subscriber ).

* WordPress® Administrators, Editors, Authors, and Contributors have Level 4 access, with respect to s2Member. All of their other Roles/Capabilities are left untouched.
~ Jason Caldwell / Lead Developer
& Zeitgeist Movie Advocate: http://www.zeitgeistmovie.com/

Is the s2Member plugin working for you? Please rate s2Member at WordPress.org.
You'll need a WordPress.org account ( comes in handy ). Then rate s2Member here Image
.
User avatar
Jason Caldwell
Lead Developer
Lead Developer
 
Posts: 4045
Joined: May 3, 2010
Location: Georgia / USA

Re: categories subscriptions/bundles

Postby syadasti » June 29th, 2010, 3:54 am

Jason,

I see what you're saying. However, my application is such that the WordPress site has no user accounts other than a) contributors and b) subscribers. All contributors are presumed authorized to view all content, so I'm using a WordPress user level rather than an s2member one.

BTW, you gotta cool it with the (r) and whatnot :)
User avatar
syadasti
Registered User
Registered User
 
Posts: 4
Joined: May 26, 2010

Re: categories subscriptions/bundles

Postby Jason Caldwell » June 30th, 2010, 7:51 am

Gotchya! hahaha... it's built into my system :-)
AceText: http://www.acetext.com/
~ Jason Caldwell / Lead Developer
& Zeitgeist Movie Advocate: http://www.zeitgeistmovie.com/

Is the s2Member plugin working for you? Please rate s2Member at WordPress.org.
You'll need a WordPress.org account ( comes in handy ). Then rate s2Member here Image
.
User avatar
Jason Caldwell
Lead Developer
Lead Developer
 
Posts: 4045
Joined: May 3, 2010
Location: Georgia / USA


Return to s2Member Plugin

Who is online

Users browsing this forum: Google [Bot], Yahoo [Bot] and 5 guests

cron