latest stable versions: v150827 (changelog)

Old Forums (READ-ONLY): The community now lives at WP Sharks™. If you have an s2Member® Pro question, please use our new Support System.

Modifying IPN url

Home Forums Community Forum Modifying IPN url

This topic contains 4 replies, has 3 voices. Last updated by  Cristián Lávaque 3 years, 8 months ago.

Topic Author Topic
Posted: Monday Apr 15th, 2013 at 3:25 am #47473
Tom
Username: halasyt

Hi,
I moved my site over from another membership software, so all the IPNs for existing recurring profiles are failing.

It doesn’t look like I can change the IPNs of the recurring profiles in PayPal, and I saw another person on this forum say that a 301 redirect didn’t work either, I guess because POST parameters are not passed with a redirect. Or is there any other way to redirect and keep the POST data?

Otherwise the only solution left is to change the IPN url of s2 to the one used by the old software. How can I do this?

Right now the IPNs are being sent to mysite.com/paypal/backend/

Thanks,
Tom

List Of Topic Replies

Viewing 4 replies - 1 through 4 (of 4 total)
Author Replies
Author Replies
Posted: Monday Apr 15th, 2013 at 12:11 pm #47502
Tom
Username: halasyt

Actually, could the simple 301 redirect be working after all? I put it into my .htaccess and had a cancellation, and I see this in the s2 paypal-ipn.log file (I put xxxxxxxx instead of the personal info). This user was created in the previous system, and even though the IPN wasn’t processed successfully, it seems like it made it into your IPN handler, correct?

LOG ENTRY: Mon Apr 15th, 2013 @ precisely 2:19 pm UTC
PHP v5.3.23 :: WordPress® v3.5.1 :: s2Member® v130406 :: s2Member® Pro v130406
Memory 39.35 MB :: Real Memory 39.75 MB :: Peak Memory 39.44 MB :: Real Peak Memory 39.75 MB
http://www.theguitarlesson.com/?s2member_paypal_notify=1
User-Agent:
array (
‘txn_type’ => ‘subscr_cancel’,
‘subscr_id’ => ‘S-9DX12439JV496345C’,
‘last_name’ => ‘xxxxxxxxx’,
‘residence_country’ => ‘US’,
‘mc_currency’ => ‘USD’,
‘item_name’ => ‘The Guitar Lesson.com – Trial Membership’,
‘business’ => ‘paypal@theguitarlesson.com’,
‘amount1’ => ‘1.00’,
‘amount3’ => ‘9.00’,
‘recurring’ => ‘1’,
‘verify_sign’ => ‘Az5lwnhJisER2nfPFJ5pgrZBvfp6Azo8Sm2Fnv9ICdrWUfFbrQwjxqHh’,
‘payer_status’ => ‘verified’,
‘payer_email’ => ‘xxxxxxxx@gmail.com’,
‘first_name’ => ‘Adam’,
‘receiver_email’ => ‘paypal@theguitarlesson.com’,
‘payer_id’ => ‘Y58SYQ83Y3LF4’,
‘reattempt’ => ‘0’,
‘subscr_date’ => ’07:18:57 Apr 15, 2013 PDT’,
‘custom’ => ‘4160’,
‘charset’ => ‘windows-1252’,
‘notify_version’ => ‘3.7’,
‘period1’ => ‘3 D’,
‘mc_amount1’ => ‘1.00’,
‘period3’ => ‘1 M’,
‘mc_amount3’ => ‘9.00’,
‘ipn_track_id’ => ‘9c6c5add11974’,
‘s2member_log’ =>
array (
0 => ‘IPN received on: Mon Apr 15, 2013 2:19:12 pm UTC’,
1 => ‘s2Member POST vars verified through a POST back to PayPal®.’,
2 => ‘Unable to verify `$_SERVER[“HTTP_HOST”]`. Please check the `custom` value in your Button Code. It MUST start with your domain name.’,
),
‘subscr_gateway’ => ‘paypal’,
)

Posted: Monday Apr 15th, 2013 at 7:40 pm #47546
Bruce
Username: Bruce
Staff Member

This user was created in the previous system, and even though the IPN wasn’t processed successfully, it seems like it made it into your IPN handler, correct?

Yes, it made it to the IPN handler, but your custom variable is wrong. You could maybe change the variable as it comes in through PHP. So that s2Member works correctly. You can find information on what s2Member expects here:

Knowledge Base » Importing Existing Subscriptions

Posted: Tuesday Apr 16th, 2013 at 2:52 am #47583
Tom
Username: halasyt

Ok, how would I go about changing the custom variable through PHP?
Based on the article you sent, I need to add my domain as a custom variable, and also the item_number.

Posted: Tuesday Apr 16th, 2013 at 4:44 am #47595

You’d need to edit the subscription profiles to add those variables to not have that problem when PayPal IPNs s2Member without all the variables. This article may also be informative: Knowledge Base » Using Buttons Generated @ PayPal.com

Not sure if it’s possible to edit the subscription profiles in PayPal, so maybe you’ll need to do something dynamically, like with a central IPN script. You can find an example one in the extras zip file in your Account page. http://www.s2member.com/account/

Does the user have the info in his WordPress profile too? Payment gateway, subscr. ID, custom. [hilite path]WP Admin -> Users -> Edit user[/hilite]

You can also manage manually these users from the previous system, and have s2Member handle the new ones created through the s2Member process. Or you can migrate them having them create a new subscription profile through s2Member and then cancel the previous one.

Viewing 4 replies - 1 through 4 (of 4 total)

This topic is closed to new replies. Topics with no replies for 2 weeks are closed automatically.

Old Forums (READ-ONLY): The community now lives at WP Sharks™. If you have an s2Member® Pro question, please use our new Support System.

Contacting s2Member: Please use our Support Center for bug reports, pre-sale questions & technical assistance.