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.

PayPal Auto Return Success Page Not Working

Home Forums Community Forum PayPal Auto Return Success Page Not Working

This topic contains 13 replies, has 2 voices. Last updated by  Bruce 4 years, 1 month ago.

Topic Author Topic
Posted: Saturday Dec 1st, 2012 at 4:27 pm #33128

Hi there:

I’m stumped trying to figure out why the auto-return to a success page isn’t working for me. Can someone provide insight?

I’m using Pro Forms with Standard PayPal (Express Checkout). When the user is returned from PayPal they get sent back to the checkout form rather than the page that I’ve entered into the short code.

Here’s the short code:

[s2Member-Pro-PayPal-Form level="1" ccaps="" desc="XYZ" ps="paypal" lc="" cc="USD" dg="0" ns="1" custom="www.recoverysuperstar.com" ta="0" tp="0" tt="D" ra="0.01" rp="4" rt="M" rr="BN" rrt="" rra="2" accept="paypal" accept_via_paypal="paypal" coupon="" accept_coupons="0" default_country_code="" captcha="0" success="http://www.xyz.com/thank-you/" /]

I noticed that in the paypal-api.log file, it says ‘SUCCESSPAGEREDIRECTREQUESTED’ => ‘false’

What might this point to as the root of my problem? Log data follows below with data Xed out for privacy.

paypal-api.log

'TOKEN' => 'EC-XXXXXXXXXXXXXXXXXXXXX',
  'SUCCESSPAGEREDIRECTREQUESTED' => 'false',
  'TIMESTAMP' => '2012-12-01T20:47:08Z',
  'CORRELATIONID' => 'XXXXXXXXXXXX',
  'ACK' => 'Success',
  'VERSION' => '71.0',
  'BUILD' => '4181146',
  'INSURANCEOPTIONSELECTED' => 'false',
  'SHIPPINGOPTIONISDEFAULT' => 'false',
  'PAYMENTINFO_0_TRANSACTIONID' => 'XXXXXXXXXXXXXXX',
  'PAYMENTINFO_0_TRANSACTIONTYPE' => 'cart',
  'PAYMENTINFO_0_PAYMENTTYPE' => 'instant',
  'PAYMENTINFO_0_ORDERTIME' => '2012-12-01T20:47:08Z',
  'PAYMENTINFO_0_AMT' => '0.01',
  'PAYMENTINFO_0_FEEAMT' => '0.01',
  'PAYMENTINFO_0_TAXAMT' => '0.00',
  'PAYMENTINFO_0_CURRENCYCODE' => 'USD',
  'PAYMENTINFO_0_PAYMENTSTATUS' => 'Completed',
  'PAYMENTINFO_0_PENDINGREASON' => 'None',
  'PAYMENTINFO_0_REASONCODE' => 'None',
  'PAYMENTINFO_0_PROTECTIONELIGIBILITY' => 'Ineligible',
  'PAYMENTINFO_0_PROTECTIONELIGIBILITYTYPE' => 'None',
  'PAYMENTINFO_0_SECUREMERCHANTACCOUNTID' => 'XXXXXXXXXXXXXXX',
  'PAYMENTINFO_0_ERRORCODE' => '0',
  'PAYMENTINFO_0_ACK' => 'Success',

paypal-ipn.log

PHP v5.3.18-1~dotdeb.0 :: WordPress® v3.4.2 :: s2Member® v121023 :: s2Member® Pro v121023
Memory 33.56 MB :: Real Memory 33.75 MB :: Peak Memory 33.65 MB :: Real Peak Memory 33.75 MB
www.xyz.com/?s2member_paypal_notify=1
User-Agent: 
array (
  'mc_gross' => '0.01',
  'protection_eligibility' => 'Ineligible',
  'item_number1' => '1::4 M',
  'payer_id' => 'XXXXXXXXXXXX',
  'tax' => '0.00',
  'payment_date' => '12:47:08 Dec 01, 2012 PST',
  'payment_status' => 'Completed',
  'charset' => 'windows-1252',
  'mc_shipping' => '0.00',
  'mc_handling' => '0.00',
  'first_name' => 'Cookie',
  'mc_fee' => '0.01',
  'notify_version' => '3.7',
  'custom' => 'www.xyz.com',
  'payer_status' => 'unverified',
  'num_cart_items' => '1',
  'mc_handling1' => '0.00',
  'verify_sign' => 'XXXXXXXXXXXXXXXXXXXXXXXXXX',
  'payer_email' => 'xxxxxxxxx@gmail.com',
  'mc_shipping1' => '0.00',
  'tax1' => '0.00',
  'txn_id' => 'XXXXXXXXXXXXX',
  'payment_type' => 'instant',
  'last_name' => 'Monster',
  'item_name1' => 'XXXXXXXXXX',
  'receiver_email' => 'xxxxxxxxx@gmail.com',
  'payment_fee' => '0.01',
  'quantity1' => '1',
  'receiver_id' => 'XXXXXXXXXXXXX',
  'txn_type' => 'cart',
  'mc_gross_1' => '0.01',
  'mc_currency' => 'USD',
  'residence_country' => 'US',
  'transaction_subject' => 'XYZ',
  'payment_gross' => '0.01',
  'ipn_track_id' => 'xxxxxxxxxxxxxxx',
  's2member_log' => 
  array (
    0 => 'IPN received on: Sat Dec 1, 2012 8:47:11 pm UTC',
    1 => 's2Member POST vars verified through a POST back to PayPal®.',
    2 => 's2Member originating domain ( `$_SERVER["HTTP_HOST"]` ) validated.',
    3 => 's2Member `txn_type` identified as ( `cart` ).',
    4 => 'The `txn_type` does not require any action on the part of s2Member.',
    5 => 's2Member Pro handles Cart events on-site, with an IPN proxy.',
  ),
  'subscr_gateway' => 'paypal',
)

paypal-rtn.log

PHP v5.3.18-1~dotdeb.0 :: WordPress® v3.4.2 :: s2Member® v121023
Memory 26.27 MB :: Real Memory 26.50 MB :: Peak Memory 26.38 MB :: Real Peak Memory 26.50 MB
www.xyz.com/?s2member_paypal_return=1&s2member_paypal_return_tra=alphanumericstringthatidontwanttoshowforprivacy=Completed&amt=0.01&cc=USD&cm=www%xyz%2ecom&item_number=1::4%20M
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_8_2) AppleWebKit/537.11 (KHTML, like Gecko) Chrome/23.0.1271.64 Safari/537.11
array (
  'mc_gross' => '0.01',
  'invoice' => 'XXXXXXXXXXX',
  'protection_eligibility' => 'Ineligible',
  'payer_id' => 'XXXXXXXXXXXXXXXX',
  'tax' => '0.00',
  'payment_date' => '18:42:24 Nov 18, 2012 PST',
  'payment_status' => 'Completed',
  'charset' => 'windows-1252',
  'first_name' => 'Cookie',
  'option_selection1' => 'www.xyz.com',
  'option_selection2' => 'xx.xx.xxx.xx',
  'mc_fee' => '0.01',
  'custom' => 'www.xyz.com',
  'payer_status' => 'unverified',
  'business' => 'xxxxxxx@gmail.com',
  'quantity' => '1',
  'payer_email' => 'xxxxxx@gmail.com',
  'option_name1' => 'Originating Domain',
  'option_name2' => 'Customer IP Address',
  'txn_id' => 'XXXXXXXXXXXXXX',
  'payment_type' => 'instant',
  'last_name' => 'Monster',
  'receiver_email' => 'xxxxxxxxxx@gmail.com',
  'payment_fee' => '0.01',
  'receiver_id' => 'XXXXXXXXXXXXXXXX',
  'txn_type' => 'web_accept',
  'item_name' => 'class registration',
  'mc_currency' => 'USD',
  'item_number' => '1::4 M',
  'residence_country' => 'US',
  'handling_amount' => '0.00',
  'transaction_subject' => 'www.xxxxxxxxxx.com',
  'payment_gross' => '0.01',
  'shipping' => '0.00',
  's2member_log' => 
  array (
    0 => 'Return-Data received on: Mon Nov 19, 2012 2:42:33 am UTC',
    1 => 's2Member POST vars verified through a POST back to PayPal®.',
    2 => 's2Member originating domain ( `$_SERVER["HTTP_HOST"]` ) validated.',
    3 => 's2Member `txn_type` identified as ( `web_accept|subscr_signup|subscr_payment` ).',
    4 => 's2Member `txn_type` identified as ( `web_accept|subscr_signup|subscr_payment` ) w/o update vars.',
    5 => 'Registration Cookies set on ( `web_accept|subscr_signup|subscr_payment` ) w/o update vars.',
    6 => 'Transient Tracking Cookie set on ( `web_accept|subscr_signup|subscr_payment` ) w/o update vars.',
    7 => 'Redirecting Customer to Registration Page. They need to Register now.',
  ),
  'subscr_gateway' => 'paypal',
  'subscr_id' => 'XXXXXXXXXXXXXXXXX',
  'eotper' => '4 M',
  'ccaps' => '',
  'level' => '1',
  'ip' => 'xx.xx.xxx.xx',
  'period1' => '0 D',
  'mc_amount1' => '0.00',
  'period3' => '4 M',
  'mc_amount3' => '0.01',
  'initial_term' => '0 D',
  'initial' => '0.01',
  'regular' => '0.01',
  'regular_term' => '4 M',
  'recurring' => '0',
  's2member_paypal_return_tra' => 'alphanumericstringthatidontwanttodisplayforprivacyreasons',
)

Thanks for your help!
Lauren

List Of Topic Replies

Viewing 13 replies - 1 through 13 (of 13 total)
Author Replies
Author Replies
Posted: Saturday Dec 1st, 2012 at 4:43 pm #33131
Bruce
Username: Bruce
Staff Member

Hi Lauren,

Based on your logs, it appears that your shortcode’s success="" attribute is not being passed to PayPal.

Is it possible that a caching plugin on your site is causing this?

If that’s not the case, please try running this Server Check Tool by uploading it to your main WordPress directory within your website, and navigating to the file within your browser. Post results in a reply.

Posted: Saturday Dec 1st, 2012 at 5:47 pm #33134

Thanks for your quick reply, Bruce. It is possible that my web host in running a caching service. (I use ZippyKid managed WordPress hosting).

Here are the results of the server check.

Server Scan By: s2Member®Test Email Functionality?

The following issues were discovered...
Tip: Notices/warnings can be dismissed (if you MUST); please read carefully.

[NOTICE] WordPress® Memory LimitAUTO-FIX!dismiss?
Although NOT required, s2Member® recommends that you raise your WordPress® memory limit (please set: WP_MEMORY_LIMIT in /wp-config.php), to at least 64M (i.e. 64 megabytes). Please see: this how-to article. Or consult with your web hosting company about this message. Your current memory limit allows only: 32M

[NOTICE] WordPress® Debugging ModeAUTO-FIX!dismiss?
Although NOT required, s2Member® recommends that your WordPress® installation be configured NOT to run in debugging mode (please set: WP_DEBUG to FALSE in /wp-config.php). If you decide to leave WP_DEBUG enabled, please take note... In WP_DEBUG mode, WordPress® will log debug messages into this file: /wp-content/debug.log. Please make ABSOLUTELY sure this file is NOT publicly accessible, as it may contain sensitive server details (in some cases). Please see this article for further details. Or consult with your web hosting company about this message.

You passed on all of these scans :-)

[PASS] PHP Version
You are currently running PHP 5.3.18-1~dotdeb.0. Minimum required version is: 5.2
[PASS] WordPress® Version
You are currently running WordPress® 3.4.2. Minimum required version is: 3.2
[PASS] Multibyte String Extension
The mbstring extension is installed. Your server supports UTF-8 character conversion.
[PASS] ZLib Extension (GZIP)
The zlib extension is installed. Your server supports GZIP compression.
[PASS] Default Hash Extension
The Hash extension is installed. Comes with every installation of PHP. Your server supports message digests.
[PASS] Default XML Parser Extension
The XML Parser extension is installed. Comes with every installation of PHP. Your server supports XML parsing.
[PASS] Default libXML Extension
The libXML extension is installed. Comes with every installation of PHP. Your server supports this important dependency.
[PASS] Default Simple XML Extension
The Simple XML extension is installed. Comes with every installation of PHP. Your server can convert XML into PHP objects.
[PASS] Default XML Reader Extension
The XML Reader extension is installed. Comes with every installation of PHP. Your server has the ability to read XML documents.
[PASS] Default XML Writer Extension
The XML Writer extension is installed. Comes with every installation of PHP. Your server has the ability to write XML documents.
[PASS] Default DOM Extension
The DOM extension is installed. Comes with every installation of PHP. Your server supports XML document traversal.
[PASS] Default Sessions Extension
The Sessions extension is installed. Comes with every installation of PHP. Your server allows read/write access to session data.
[PASS] MySQL Database Extension
The MySQL extension is installed. Your server supports MySQL database communication.
[PASS] Mcrypt/Encryption Extension
The Mcrypt extension is installed. Your server supports advanced data encryption.
[PASS] Default JSON Extension
The JSON extension is installed. Comes with every installation of PHP. Your server supports JavaScript object notation.
[PASS] GD Image Extension (JPEG/PNG/FreeType)
The GD Image extension is installed. Your server supports dynamic image creation.
[PASS] Default Fileinfo Extension
The Fileinfo extension is installed. Comes with every installation of PHP 5.3+. Your server supports MIME type detection.
[PASS] Default Ctype Extension
The Ctype extension is installed. Comes with every installation of PHP. Your server supports character class detection.
[PASS] PHP eval() Function
The eval() function is available.
[PASS] PHP ini_get() Function
The ini_get() function is available.
[PASS] cURL Extension With SSL Support
The cURL extension for remote communication via PHP is available (and the OpenSSL extension for PHP is enabled).
[PASS] INI fopen() URL With SSL Support
The setting allow_url_fopen is on in your php.ini file (and the OpenSSL extension for PHP is enabled).
[PASS] OpenSSL Extension With openssl_sign()
The OpenSSL extension is installed, and PHP function openssl_sign() is available.
[PASS] Temporary Files Directory
A readable/writable temporary files directory was found here: /tmp
[PASS] $_SERVER['DOCUMENT_ROOT']
Your server reports this value: /htdocs
[PASS] $_SERVER['HTTP_HOST']
Your server reports this value: www.xyz.com
[PASS] $_SERVER['REQUEST_URI']
Your server reports this value: /s2member-server-check-120703.php
[PASS] $_SERVER['REMOTE_ADDR']
Your server reports this value: xx.xx.xx.xxx
[PASS] $_SERVER['HTTP_USER_AGENT']
Your server reports this value: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_8_2) AppleWebKit/536.26.17 (KHTML, like Gecko) Version/6.0.2 Safari/536.26.17
[PASS] $_SERVER['SERVER_ADDR']
Your server reports this value: 10.176.161.85
[PASS] WordPress® MAX Memory Limit
Your WordPress® MAX memory limit (WP_MAX_MEMORY_LIMIT in /wp-config.php, or by default), is set to: 256M
[PASS] WordPress® External HTTP Requests
Your WordPress® External HTTP Requests (WP_HTTP_BLOCK_EXTERNAL in /wp-config.php, or by default), is set to: FALSE
[PASS] WordPress® DB Charset
Your WordPress® database charset (DB_CHARSET in /wp-config.php, or by default), is set to: utf8
[PASS] WordPress® DB Collation
Your WordPress® database collation (DB_COLLATE in /wp-config.php, or by default), is set to: an empty string
[PASS] WordPress® Character Encoding
Your WordPress® installation is operating with UTF-8 encoding, under: WordPress -› Settings -› Reading -› Encoding.
[PASS] WordPress® Home URL
Your WordPress® home URL is configured to run on: www.recoverysuperstar.com, and that matches the current host name: www.recoverysuperstar.com
[PASS] WordPress Site URL
Your WordPress® site URL is configured to run on: www.xyz.com, and that matches the current host name: www.xyz.com

What do you recommend? If I need to get help from the managed hosting company what do I need to ask of them?

There are a few plugins that were installed and activated by the host: Debug Bar, Developer, Log Deprecated Notices and Use Google Libraries. Not sure if this is relevant.

Thanks for your help!
Lauren

Posted: Saturday Dec 1st, 2012 at 5:51 pm #33135
Bruce
Username: Bruce
Staff Member

Hi Lauren,

Nothing is jumping out at me as to what might be the cause of this, your Server Check looks fine.

Could you send me a link to the page with the ShortCode on it so I might take a look and see if the the page is passing the success attribute?

Thanks.

Posted: Saturday Dec 1st, 2012 at 5:55 pm #33136

Sure, here you go:
http://www.xyz.com/sign-up/checkout/

  • This reply was modified 4 years, 1 month ago by  Bruce. Reason: Remove URL
Posted: Saturday Dec 1st, 2012 at 6:18 pm #33139
Bruce
Username: Bruce
Staff Member

Hi Lauren,

The problem lies within your success=”” attribute you have in your first post. Just change success="http://www.xyz.com/thank-you/ " to success="/thank-you/".

That should solve your issue.

  • This reply was modified 4 years, 1 month ago by  Bruce.
Posted: Saturday Dec 1st, 2012 at 6:28 pm #33141

Actually, I had originally set the short code to

success="/thank-you/"

but changed it to the complete URL in case that was the issue. I just changed it back, cleared my cache, tested it and it still doesn’t work. :(

Posted: Saturday Dec 1st, 2012 at 6:42 pm #33143
Bruce
Username: Bruce
Staff Member

Hi Lauren,

That’s very interesting. You said that PayPal is sending your users back to the signup page. Are you sure that you have the correct URL set up within your PayPal account? Find info on this in Dashboard -› s2Member® -› PayPal® Options -› PayPal® PDT Integration.

Posted: Saturday Dec 1st, 2012 at 7:04 pm #33146

Hi Bruce:

Thanks for being so responsive.

I just double checked the PayPal account settings and the URL is correct.
Auto Return is On
PDT is On
I have a token that is entered in to s2member

PayPal is sending users back to the checkout page. They get the “Thank you message” that is embedded within the checkout form.

Any other ideas?
Lauren

Posted: Saturday Dec 1st, 2012 at 7:32 pm #33152
Bruce
Username: Bruce
Staff Member

Hi Lauren,

After doing a bit of digging, I believe that the problem may be that your server’s hosting environment is not allowing loopbacks. Someone else had this issue in this thread:

http://www.s2member.com/forums/topic/paypal-success-return-url-not-working/

Can you try uploading a Must Use plugin with the following data in it (you can do this by putting a .php file within your /wp-content/mu-plugins/ directory on your server, create the directory if you don’t already have it)?:

http://’ . $_SERVER[‘HTTP_HOST’]));
exit;
}
[/hilite]

You should then navigate to http://www.recoverysuperstar.com/?s2_diagnostics and see if it gives you errors.

Posted: Saturday Dec 1st, 2012 at 7:42 pm #33154

Thank you for your persistence, Bruce. I followed your instructions and here’s the error I got:

WP_Error Object
(
    [errors] => Array
        (
            [http_request_failed] => Array
                (
                    [0] => Recv failure: Connection reset by peer
                )

        )

    [error_data] => Array
        (
        )

)

What does it mean?

Posted: Saturday Dec 1st, 2012 at 7:50 pm #33155
Bruce
Username: Bruce
Staff Member

Hi Lauren,

This means that your hosting provider is not allowing your site to loopback, which is causing s2Member not to work correctly. You should contact your hosting provider and have them enable loopbacks, and if you cannot get them to enable this feature, you will have to switch hosting providers to have s2Member function correctly. This could cause more problems in the future, so you should attempt to have this fixed before you go live.

We recommend any of these hosts:
http://wordpress.org/hosting/

Also recommend:
HostGator
MediaTemple (gs)
Rackspace Cloud Hosting
FireHost

Posted: Saturday Dec 1st, 2012 at 7:56 pm #33158

Thank you so much, Bruce. I really appreciate your help with this. I would have never figured this out on my own.

Posted: Saturday Dec 1st, 2012 at 7:59 pm #33159
Bruce
Username: Bruce
Staff Member

No problem.

Let us know if you have any further issues with this, or anything else.

Viewing 13 replies - 1 through 13 (of 13 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.