Page 1 of 1

Free Purchases for existing members

PostPosted: July 18th, 2011, 10:03 am
by scottgould
Hi Guys

I so love s2Member that I am using to process all payments on our site, for both memberships and events. Mainly this is because I can use the Oro Forms, and therefore take payments on my site. And it also allows me to have a standardised payment system across all events.

I have successfully created a set of functions which act as a bridge between Wordpress Event Manager Pro (http://wp-events-plugin.com/), and S2member. I use Event Manager pro to manage the bookings, and send them off to S2memeber to pay. I am using the notifications scripting to ping a script that then confirms the bookings and sends emails.

I am using Custom Capabilities more than levels. I am only using level 1 - putting everyone on that level - and then adding capabilities as I see fit. It is those capabilities that I then hide content / change prices / etc.

However I am coming to the point where I inevitably have issues with this process.

The first scenario is thus:

1. I have a member who signs up to join our Club. They have level 1 and a capability of +club.

2. Then I have the same member who purchases a ticket for an event. The level stays the say, and a new capability of +eventslug is added.

3. This same member is invited to attend a second event, with a code that gives him 100% off, as he is staff for the event. Now I have a dilemma. Event Manager Pro does not have coupons, and I know that S2member requires a minimum amount as it is a checkout page. I understand this.

I can't put this person onto a registration form as an alternative, because that asks him a new for his username, password, etc, as if he were not a member.

Is there a way to put him through a form that adds new capabilities, but does not ask for payment, nor asks for registration details?

The second scenario is:

Lets say that I decide to create levels of membership. Club membership is level 2, whereas an event membership is level 1.

If a Club member purchases an event membership, can I stop them from being downgraded?

Is it possible to leave the "Level=1" field from the pro-form?



Thank you both so much for your help,
Scott

Re: Free Purchases for existing members

PostPosted: July 19th, 2011, 9:48 pm
by Cristián Lávaque
Hi Scott.

I haven't tried either scenario, and the first one I'll leave for Jason because I'm not sure what to suggest.

For the second one, though, have you tried changing the level dynamically? so that if the user already is at Level 2 and wants to buy the ccap for Event Membership, you can change the level to 2 in the shortcode. viewtopic.php?f=36&t=1604

Let me know if that helps.

Re: Free Purchases for existing members

PostPosted: July 21st, 2011, 3:06 pm
by Jason Caldwell
Is there a way to put him through a form that adds new capabilities, but does not ask for payment, nor asks for registration details?
Sorry, not yet. However, you can do something like this in PHP.
Code: Select all
<?php
$user 
= wp_get_current_user();
$user->add_cap("access_s2member_ccap_music");
?>

Re: Free Purchases for existing members

PostPosted: July 21st, 2011, 3:46 pm
by scottgould
Thanks guys for letting me know!

Re: Free Purchases for existing members

PostPosted: July 21st, 2011, 4:17 pm
by Cristián Lávaque
:)