Redirecting existing / expired members from signup.php to member.php

Discussion in 'Customization & add-ons' started by nomaddesign, Dec 11, 2008.

  1. nomaddesign

    nomaddesign Member

    Joined:
    Aug 25, 2005
    Messages:
    67
    Has anyone tried redirecting existing or expired members from signup.php to member.php? Some of our existing members will signup as a new member with a different email address rather than log-in.

    -- Does 3.1.1's new AJAX signup handle this better? (I'm on 3.0.9 )

    Is there a aMember cookie that that will tell me if someone is a member? (not just logged in)

    Any suggestions or approaches to the "existing member signing up again" problem would be appreciated.

    Thanks!
  2. miso

    miso aMember Pro Customer

    Joined:
    Aug 22, 2006
    Messages:
    543
    well, you could either put a big link/button above the signup form saying something like "If you are a member already, please log in first".

    Or, you could check for existence of their member data being set in the browser session, and if it is then you display a log in button/link to member.php so that they can purchase/signup through there... otherwise, display the signup form instead.
  3. nomaddesign

    nomaddesign Member

    Joined:
    Aug 25, 2005
    Messages:
    67
    Yeah, I've got a link at the top in Bold.... But there are still members who blow-by that and "sign-up" with a different email. I've got an older less internet savy audience...

    I'd like to check for the existence of "member data" of members who are not logged-in. My knowledge of php cookies is pretty rough. (but that may change soon)

    So to clarify my question, is there a way to check cookies to determine if a user has ever logged in as a member. If so how.

    Thanks!
  4. alexander

    alexander Administrator Staff Member

    Joined:
    Jan 8, 2003
    Messages:
    6,279
    By default aMember use php sessions to handle login, so there is no lifetime cookie being set when user login.
    You can set it yourself from site.inc.php:
    <?
    setup_plugin_hook("after_login", "set_member_cookie");
    function set_member_cookie($user){
    amember_setcookie("amember_existing_user", 1);
    }
    ?>

    Then you can test it on signup.php

Share This Page