After payment login link not to S2 dashboard but WP dashboard

Paypal redirects to an S2 page (image #1) after buyer completes order of a ccap product which can only be bought once they are inside the membership. This page pops up directing person to click and login once again. If they click the link they are NOT directed to the dashboard that is setup in S2 but to a WP menu and clicking on the dashboard does NOT take them to the “REAL” dashboard setup in S2. The only way to get there would be to logout and log back in.

Is there a way to change the login link on the S2 page right after payment?

Image #1 - if click login, does not take to S2 dashboard page but takes to WP dashboard instead

Image #2 - not the dashboard page setup with S2

What do you have your auto-return page configured to?

I have it set to the auto return URL given by S2`

The client was logged in as a free member, bought a ccap which boosted to level 1 and applied the ccap correctly…client was added as a paid member level 1…all that works just fine, its just the login on that image page I provided that takes them to the WP dashboard rather than the S2 dashboard page designated by S2.

I did find the Remove Dashboard Access plugin that would redirect to the right page but have not tested it yet. Would rather not use a plugin if possible…am not using S2 Pro which I know could take care of that but client will decide later on that issue.

This is a tricky one because the problem you are reporting is on a live site. So I assume testing scenarios is not simple.

I have it set to the auto return URL given by S2`

I do notice that in your url description above there is a quote after the return=1. Is that just a cut & paste artifact?

Additionally, is this url set in the settings or in the shortcode?

That was just a paste error…the proper url is setup in the paypal return API with Identity token and it does work since it redirected the buyer to the S2 page that has the message to “log back in ( click here)” message. It’s just that when one clicks on that link, it takes the person to the WP dashboard and not the S2 page that is configured as their dashboard. I have not yet tested the plugin to see if it takes care of that.

Ok…just checking :slight_smile:

I took a look in the source code and the software has odd decision logic. If there is a custom url configured then the software will redirect to it otherwise it directs them to the standard WordPress login (which is why you end up at the dashboard).

I’m not sure what the coder was thinking there but it looks like to solve your problem you need to add the target url parameter to the PayPal button shortcode.


Don’t shoot me if I’m wrong…that’s just what the sourcecode seems to be looking for :slight_smile:

thanks…I had seen that but was under the assumption that it only worked with S2 Pro…

I agree the documentation is confusing. The following quote though reinforces what I saw in the code:

Tip : In addition to the default Auto-Return/PDT configuration inside your PayPal Merchant Account the Auto-Return URL is also set on a per-transaction basis from within the PayPal Button shortcode that s2Member generates. In other words, if you have multiple sites operating on one PayPal account, that is OK. s2Member sets the Auto-Return URL dynamically for each transaction. The result is that the Auto-Return URL configured from within your PayPal account becomes the default which may be overwritten on a per-transaction basis by s2Member .

PayPal Pro : The tip above (for PayPal Payments Standard ) is also true for PayPal Pro integration.

Let us know how you go.

Not sure I fully understand…but…if I were to add the success with URL at the end of the paypal button shortcode that is generated, then there is probability that it will work as expected.
I will give it a try.
Thank you for being my sounding board…

You got it :slight_smile: