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 S2 Read Another Subscription Button's IPN?

s2Member Plugin. A Membership plugin for WordPress®.

Can S2 Read Another Subscription Button's IPN?

Postby KirkWard » October 26th, 2010, 5:05 pm

That being said, PayPal's service "Website Payments Standard" will not allow the IPN communication to be transferred from your old system to your new system. At least not for existing Subscriptions that existed before you made the switch to s2Member. Going forward you'll be fine, but old "Subscriptions" will NOT be communicated to s2Member via IPN, because they were created by a different piece of software


I use an IPN Relay script to receive the PayPal "Website Payments Standard" IPN and then forward it to three different scripts, WishList Member, iDevAffiliate, and a custom script I use to subscribe new members to my autoresponder. Each uses the IPN properly, extracting the information it needs. The only data in the CUSTOM field is the buyers IP address, which iDevAffiliate uses in some way.

If I use this IPN relay script to also point the IPN to the correct S2 URL, will S2 read the IPN and manage subscribers I have manually added?
User avatar
KirkWard
Experienced User
Experienced User
 
Posts: 61
Joined: October 22, 2010

Re: Can S2 Read Another Subscription Button's IPN?

Postby Jason Caldwell » October 27th, 2010, 5:53 am

Great question Kirk.

No, because when/if you are forwarding IPN responses to s2Member from a former integration with another piece of software, you would be required to modify the "custom" variable, and also the "item_number" variable to match what s2Member expects in the IPN response.

Changing those variables would break the PayPal verification system that is implemented internally by s2Member. In other words, when s2Member sends a POST back to PayPal for verification, PayPal would report "UN-Verified", because the variables would not match what was originally transacted.

That being said, s2Member does provide a way around this issue. You can use the "IPN w/ Proxy Key" supplied by s2Member. In your Dashboard, see: s2Member -> PayPal Options -> IPN Integration. Using this special version of your IPN processor, you will be able to circumvent the issue I just described. However, you will still need to make sure that you dynamically modify the following two variables appropriately in the script that you write to forward the IPN response to s2Member ( e.g. your proxy script ).

custom = this MUST be the domain name where s2Member is installed.
( ex: custom=www.example.com )

item_number = this MUST be 1-4 ( indicating Membership Level )
( ex: item_number=1 )

-------------------------------------------------------------

item_number could also include
Custom Capabilities, and/or a fixed term length.

item_number = 1,2,3, or 4

-- OR --

item_number = level:custom capabilities:fixed term
Level #1 access, + music,videos as Custom Capabilities - account expires in 1 month.
( ex: 1:music,videos:1 M )
~ 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: Can S2 Read Another Subscription Button's IPN?

Postby KirkWard » October 27th, 2010, 7:14 am

That is cool, and VERY powerful. I am really impressed!

One question about the CUSTOM field ... regarding iDevAffiliate integration.

iDev wants the customer IP address. Will s2 accept the ipn if it has that additional data delimited in the CUSTOM field? (If so, what is the delimiter, a comma?)

Cheers and happy thoughts,
User avatar
KirkWard
Experienced User
Experienced User
 
Posts: 61
Joined: October 22, 2010

Re: Can S2 Read Another Subscription Button's IPN?

Postby Jason Caldwell » October 27th, 2010, 7:36 am

Thanks Kirk, very much.

Yes, you will need to make sure it "starts" with your domain name. Then you can pipe (|) delimit additional custom variables in along with it. These additional custom variables can be referenced later through s2Member's API Notifications and inside emails using %%cv1%%, %%cv2%%, etc. You'll find the details on this in your Dashboard. For example, this is discussed in the Replacement Codes for each API Notification that s2Member processes.

Examples:
custom=www.example.com|123.433.643.444
custom=www.example.com|123.433.643.444|google

The domain is used for verification.
%%cv1%% = 123.433.643.444
%%cv2%% = google
~ 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: Can S2 Read Another Subscription Button's IPN?

Postby KirkWard » October 27th, 2010, 7:39 am

Ah, yes.

I saw that and didn't quite understand. This clarifies. Thanks.
User avatar
KirkWard
Experienced User
Experienced User
 
Posts: 61
Joined: October 22, 2010

Re: Can S2 Read Another Subscription Button's IPN?

Postby Jason Caldwell » October 27th, 2010, 7:39 am

I'm attaching a sample script that comes packaged as an /extra/ with each copy of s2Member Pro. This is not exactly what you're trying to accomplish, but it might be helpful in some way. The sample script is designed for use with s2Member Pro, when/if a site owner needs to implement s2Member on multiple domains with only PayPal account. We refer to this as a central IPN processor.

central-ipn-sample.zip
(1.27 KiB) Downloaded 27 times
~ 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: Can S2 Read Another Subscription Button's IPN?

Postby KirkWard » October 27th, 2010, 9:21 am

Thanks, this looks like a good guide.

Will play with it.
User avatar
KirkWard
Experienced User
Experienced User
 
Posts: 61
Joined: October 22, 2010


Return to s2Member Plugin

Who is online

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

cron