Community Support Forums — WordPress® ( Users Helping Users ) — 2011-07-27T23:40:38-05:00 http://www.primothemes.com/forums/feed.php?f=4&t=14138 2011-07-27T23:40:38-05:00 http://www.primothemes.com/forums/viewtopic.php?t=14138&p=29385#p29385 <![CDATA[Re: No answer? Disable user login confirmation for paying us]]>
I'll keep trying to help with what I can, so keep asking if you have trouble/questions with s2Member. :)

Statistics: Posted by Cristián Lávaque — July 27th, 2011, 11:40 pm


]]>
2011-07-27T23:33:07-05:00 http://www.primothemes.com/forums/viewtopic.php?t=14138&p=29382#p29382 <![CDATA[Re: No answer? Disable user login confirmation for paying us]]> Statistics: Posted by rwilki — July 27th, 2011, 11:33 pm


]]>
2011-07-27T23:08:39-05:00 http://www.primothemes.com/forums/viewtopic.php?t=14138&p=29379#p29379 <![CDATA[Re: No answer? Disable user login confirmation for paying us]]>
candy wrote:
I am sorry Christian, but your code definitely does not log the user in :-(
It prevents that second screen to appear (the one which usually appears after registration, asking the fresh user to log in) but when I try to access a page which would only be available to a registered user, it sends me to the memberships page, asking me to pay again! (which is wrong). And the user is definitely not "in".


That's odd, in my tests it logs me in and takes me to the Login Welcome Page, which is protected at Level 0 and I wouldn't be able to see unless logged in.

Just tested with a Level 1 link to register, got logged in automatically again. Went to my admin account, loaded the profile for the new account and it was properly set at Level 1.

There must be something in your installation that's interfering with this if it doesn't work for you. I'm using the latest WordPress and s2Member, TwentyTen theme and only a couple other plugins installed.

Statistics: Posted by Cristián Lávaque — July 27th, 2011, 11:08 pm


]]>
2011-07-27T23:02:17-05:00 http://www.primothemes.com/forums/viewtopic.php?t=14138&p=29378#p29378 <![CDATA[Re: No answer? Disable user login confirmation for paying us]]>
That said, I mentioned this to Jason earlier and it's being considered, but I have no date for it since there are several other things to be done as well.

Statistics: Posted by Cristián Lávaque — July 27th, 2011, 11:02 pm


]]>
2011-07-27T21:48:26-05:00 http://www.primothemes.com/forums/viewtopic.php?t=14138&p=29368#p29368 <![CDATA[Re: No answer? Disable user login confirmation for paying us]]> Statistics: Posted by rwilki — July 27th, 2011, 9:48 pm


]]>
2011-07-27T21:25:16-05:00 http://www.primothemes.com/forums/viewtopic.php?t=14138&p=29366#p29366 <![CDATA[Re: No answer? Disable user login confirmation for paying us]]>
It prevents that second screen to appear (the one which usually appears after registration, asking the fresh user to log in) but when I try to access a page which would only be available to a registered user, it sends me to the memberships page, asking me to pay again! (which is wrong). And the user is definitely not "in".

I did not find a solution for the redirect either, I think it should be an integrated function, as sending the user to a central always same page is not logical if you have a site with more let's say products or options different from each other. If the user land to the welcome page, he will not likely NOt know his way back to the page he was actually interested in. Does not make much sense, you know?

Would be nice if you or Jason would have a solution for us :-)

Thanks

Statistics: Posted by candy — July 27th, 2011, 9:25 pm


]]>
2011-07-26T08:51:48-05:00 http://www.primothemes.com/forums/viewtopic.php?t=14138&p=29184#p29184 <![CDATA[Re: No answer? Disable user login confirmation for paying us]]> Statistics: Posted by rwilki — July 26th, 2011, 8:51 am


]]>
2011-07-20T22:09:01-05:00 http://www.primothemes.com/forums/viewtopic.php?t=14138&p=28761#p28761 <![CDATA[Re: No answer? Disable user login confirmation for paying us]]>
No, mu there stands for "must use".

What version of WordPres and s2Member are you using? Where did you try using the code I gave you?

Statistics: Posted by Cristián Lávaque — July 20th, 2011, 10:09 pm


]]>
2011-07-20T21:52:22-05:00 http://www.primothemes.com/forums/viewtopic.php?t=14138&p=28755#p28755 <![CDATA[Re: No answer? Disable user login confirmation for paying us]]>
Did you by any chance mean a MU site? Cause your code definitely does NOT work for me :-(
Not even the autologin. If I use your code it keeps asking for me to enter the login credentials, if I use the other one (see above) in functions.php it makes it through the autologin, but keeps redirecting me to "mydomain.com/?page_id=0" (no idea where it taked that page_id=0 from) after I logged in

So unfortunatelly after all this I am deep in the same fogg as I was in the beggining :-(

:cry:

Statistics: Posted by candy — July 20th, 2011, 9:52 pm


]]>
2011-07-19T22:02:23-05:00 http://www.primothemes.com/forums/viewtopic.php?t=14138&p=28667#p28667 <![CDATA[Re: No answer? Disable user login confirmation for paying us]]> WP Admin -> s2Member -> API / Scripting -> Membership Options Page Variables

They don't do anything or are expected to remain for later pages either. You can, though, save those values somewhere where they won't be lost and you will be able to use later, that's why earlier I suggested saving them into a cookie or the session.

The autologin code I posted worked for me in an installation with the latest versions of WordPress and s2Member (WP 3.2.1, s2M 110710).

See the line with wp_redirect() in my code? If you stored the MOP vars somewhere, you can then use that info to redirect the user there after registration.

I hope that helps. :)

If you don't know how to do this, you should look for a developer that helps you implement it. A good one should be able to get this done without much effort. You can look for one in freelance websites like jobs.wordpress.net, oDesk, eLance.

Statistics: Posted by Cristián Lávaque — July 19th, 2011, 10:02 pm


]]>
2011-07-19T11:58:43-05:00 http://www.primothemes.com/forums/viewtopic.php?t=14138&p=28658#p28658 <![CDATA[Re: No answer? Disable user login confirmation for paying us]]> Statistics: Posted by candy — July 19th, 2011, 11:58 am


]]>
2011-07-18T11:34:03-05:00 http://www.primothemes.com/forums/viewtopic.php?t=14138&p=28616#p28616 <![CDATA[Re: No answer? Disable user login confirmation for paying us]]>
me again ... I have tried with this function in the theme's functions.php

Code:
function auto_login($userID) {
    if (!is_user_logged_in()) {
        $user = get_userdata($userID);
        $user_id = $user->ID;
        $user_login = $user->user_login;

        //login
        wp_set_current_user($user_id, $user_login);
        wp_set_auth_cookie( $user_id, $remember, $secure );
        do_action('wp_login', $user_login);
       
    }
}
add_action('user_register', 'auto_login');


Autologin works fine, what does NOT work however is to send the user back to the page he came from.

As I already have those

list($seeking, $id) = preg_split("/-/", $_GET["s2member_seeking"], 2);
list($seeking, $uri) = preg_split("/-/", $_GET["s2member_seeking"], 2);
list($seeking, $file) = preg_split("/-/", $_GET["s2member_seeking"], 2);

on the memberships page, I really do not know what else I can do.

To me it looks like a bug of some sort (maybe through the paypal communication, I don't know) or there are secret tricks that one should employ to get those variables passed through to paypal, back and through the autologin.

Fact is it does not work, and that's a serious issue, as I do not want the user to land to an irrelavant page - I want him 2 be able to turn back to the very page he started at.
Actually, I think no one wants that :-)

How can this be solved please?

Thank you!


PS: Reminder: I am not (!) a programmer, so please try to reply as for "newbies" ;) Thanks"

Statistics: Posted by candy — July 18th, 2011, 11:34 am


]]>
2011-07-17T18:12:38-05:00 http://www.primothemes.com/forums/viewtopic.php?t=14138&p=28593#p28593 <![CDATA[Re: No answer? Disable user email confirmation for paying us]]>
Well, whatever I try it does not seem to work ...
The snippet you wrote does not do the trick either, unfortunatelly ... :-(
It does not even get me pass that annoying login screen, leave alone the redirect.

I do not have a programmer, and actually s2 is promising to do that redirect:

"... s2Member to provide information about what the User/Member was attempting to access ( e.g. before they were redirected to the Membership Options Page ). This is where s2Member's MOP Vars come in ( i.e. Membership Options Page Variables ). Whenever s2Member redirects a User/Member to your Membership Options Page, it will include these important MOP Variables in the query string of the URL. These Variables can be used to provide more informative messages; or even to provide a different set of Membership Options ( i.e. Payment Buttons ), based on what a User/Member was attempting to access."

But it obviously doesn't :-(

I tried this in s2-hacks.php:

Code:
add_action('ws_plugin__s2member_during_configure_user_registration_front_side', 's2_auto_login_after_registration');
function s2_auto_login_after_registration($vars = array()) {
    wp_set_auth_cookie($vars['user_id'], false, is_ssl());
    $referer = remove_query_arg( array( 'action', 'instance' ), wp_get_referer() );
   wp_redirect( $referer );
    exit;
}


No success :-(

How do I solve it than?

Any way to include smth. in that paypal button maybe !?!? And if ... than what !??!

Thanks a lot!

Statistics: Posted by candy — July 17th, 2011, 6:12 pm


]]>
2011-07-16T23:25:16-05:00 http://www.primothemes.com/forums/viewtopic.php?t=14138&p=28555#p28555 <![CDATA[Re: No answer? Disable user email confirmation for paying us]]>
/wp-content/mu-plugins/s2hacks.php
Code:
<?php
add_action
('ws_plugin__s2member_during_configure_user_registration_front_side', 's2_auto_login_after_registration');
function s2_auto_login_after_registration($vars = array()) {
    wp_set_auth_cookie($vars['user_id'], false, is_ssl());
    wp_redirect(S2MEMBER_LOGIN_WELCOME_PAGE_URL);
    exit;
}
?>


That takes the new user to the Login Welcome Page after registration. You can change the URL to whatever you want, maybe a special page to welcome a new member.

In your case, where you want to take the person to the page he was at when he got taken to the Membership Options Page, you'll need to store that page somewhere so you can later tell which it was. Maybe save it in a cookie and get it from there later. However you do it, it'll have to also be able to deal with those that bought without having tried to view a protected page.

Ask your develper to help you with this part. If you don't have one, there are many in websites like jobs.wordpress.org, oDesk, eLance, etc.

I hope that helps. :)

Statistics: Posted by Cristián Lávaque — July 16th, 2011, 11:25 pm


]]>
2011-07-16T17:53:46-05:00 http://www.primothemes.com/forums/viewtopic.php?t=14138&p=28530#p28530 <![CDATA[Re: No answer? Disable user email confirmation for paying us]]>
I did not understand where to add / use that code you've just mentioned?

`ws_plugin__s2member_during_configure_user_registration_front_side`

Statistics: Posted by candy — July 16th, 2011, 5:53 pm


]]>
2011-07-16T17:17:50-05:00 http://www.primothemes.com/forums/viewtopic.php?t=14138&p=28522#p28522 <![CDATA[Re: No answer? Disable user email confirmation for paying us]]> https://wordpress.org/support/topic/aut ... st-1732782

You could modify it to work with an s2Member hook, like 'ws_plugin__s2member_during_configure_user_registration_front_side'.

Statistics: Posted by Cristián Lávaque — July 16th, 2011, 5:17 pm


]]>
2011-07-16T17:01:00-05:00 http://www.primothemes.com/forums/viewtopic.php?t=14138&p=28519#p28519 <![CDATA[Re: No answer? Disable user email confirmation for paying us]]>
a hack/trick whatever would be great!

Statistics: Posted by candy — July 16th, 2011, 5:01 pm


]]>
2011-07-16T16:45:49-05:00 http://www.primothemes.com/forums/viewtopic.php?t=14138&p=28517#p28517 <![CDATA[Re: No answer? Disable user email confirmation for paying us]]> Statistics: Posted by Cristián Lávaque — July 16th, 2011, 4:45 pm


]]>
2011-07-16T16:26:13-05:00 http://www.primothemes.com/forums/viewtopic.php?t=14138&p=28516#p28516 <![CDATA[Re: No answer? Disable user email confirmation for paying us]]> Statistics: Posted by candy — July 16th, 2011, 4:26 pm


]]>
2011-07-16T08:01:40-05:00 http://www.primothemes.com/forums/viewtopic.php?t=14138&p=28492#p28492 <![CDATA[Re: Disable user email confirmation for paying users - how?]]>
Thanks!

Statistics: Posted by candy — July 16th, 2011, 8:01 am


]]>
2011-07-15T18:52:04-05:00 http://www.primothemes.com/forums/viewtopic.php?t=14138&p=28454#p28454 <![CDATA[Re: Disable user email confirmation for paying users - how?]]>
I, personally hate the activation emails as they often end up in spam or people don't want to have to go through the whole process of clicking links etc.

I agree, for paid users there is absolutely no need to have the activation email.

I'd be happy with just a decent captcha for Buddypress signups that were free too and cut out the whole activation email cycle.

If it has to be the way with free members then so be it but for premium it would be great to cut that step out!

Statistics: Posted by rossagrant — July 15th, 2011, 6:52 pm


]]>
2011-07-15T17:49:36-05:00 http://www.primothemes.com/forums/viewtopic.php?t=14138&p=28453#p28453 <![CDATA[No answer? Disable user login confirmation for paying users?]]>
Ok, just got that sandbox to get trhough a registration, and I need to change one very annoying WP behaviour, namely forcing the user to confirm his registration.

That might make lots of sense for free registrations, but when I have a user who pays I definitely do not need to loop him through an even more messy registration process (the whole paypal story is annoying & complicated enough).

So I want him to be automatically logged in once he filled in his user name & pass, and not wait 4 him to 1st confirm it by clicking in that email.

The reason is that I want the user to get as quickly as possible to see a certain page (which actually sent him through the whole registration pain) and not make his life really impossible with 10000000 annoying steps.

If he paid, and paypal sent him back as "ok" to my site, I don't need that extra mile, really.

So what do I have 2 change an where so that when a user is sent back from paypal after completing a payment, all he has to do is enter an username & pasword and once he cliks "register" he'll be automatically and imediatelly logged in into the site (and sent to the page he originally came from, before going through the whole paypal process)?

This is VERY important!

Thank you!

PS: free registration disabled!

Statistics: Posted by candy — July 15th, 2011, 5:49 pm


]]>