Tips and Tricks HQ Forum

Support Forum for Tips and Tricks HQ Products

Register or log in - lost password? (Having an issue with the forum login?)

Search the Forum

Tips and Tricks HQ Forum » WP eMember

Warning array errors upon login to eMember

(12 posts) (4 voices)
  • Started 1 year ago by hoffybalboa
  • Latest reply from bastywebb
  • Possible Solutions (Related Topics):
    1. WPeMember - Warning: array key exists
    2. "Warning: Cannot modify header information" upon login
    3. eMember - No error messages appearing on failed login
    4. WP eMember - Creating or Customizing the Compact Login Widget/Links

Tags:

  • cannot modify header inforamtion
  • eMember
  • login
  • warning array
12Next »
  1. hoffybalboa
    Member

    Hi,

    I have successfully integrated eMember, and the WP-Affiliate platform using eMember to create the membership, affiliate, and wordpress user upon successful registration.

    When someone registers, all 3 accounts are created. However the member is supposed to be automatically signed into wordpress upon login so they can comment on posts. This is not working. The wordpress account is created but the user is not logged in.

    In addition, when the user logs in, I get the following errors:

    Warning: array_keys() [function.array-keys]: The first argument should be an array in /home/jwepper/public_html/apartments/dallas/wp-content/plugins/wp-eMember/wp_eMember1.php on line 76

    Warning: in_array() [function.in-array]: Wrong datatype for second argument in /home/jwepper/public_html/apartments/dallas/wp-content/plugins/wp-eMember/wp_eMember1.php on line 77

    Warning: Cannot modify header information - headers already sent by (output started at /home/jwepper/public_html/apartments/dallas/wp-content/plugins/wp-eMember/wp_eMember1.php:76) in /home/jwepper/public_html/apartments/dallas/wp-includes/pluggable.php on line 690

    Warning: Cannot modify header information - headers already sent by (output started at /home/jwepper/public_html/apartments/dallas/wp-content/plugins/wp-eMember/wp_eMember1.php:76) in /home/jwepper/public_html/apartments/dallas/wp-includes/pluggable.php on line 691

    Warning: Cannot modify header information - headers already sent by (output started at /home/jwepper/public_html/apartments/dallas/wp-content/plugins/wp-eMember/wp_eMember1.php:76) in /home/jwepper/public_html/apartments/dallas/wp-includes/pluggable.php on line 692

    Warning: Cannot modify header information - headers already sent by (output started at /home/jwepper/public_html/apartments/dallas/wp-content/plugins/wp-eMember/wp_eMember1.php:76) in /home/jwepper/public_html/apartments/dallas/wp-content/plugins/wp-eMember/wp_eMember1.php on line 92

    Any help would be appreciated. Thank you

    Posted 1 year ago #
  2. amin007
    Key Master

    Can you please very that you have the "Automatically log into Wordpress" option checked in your eMember settings?

    Also, can you try the login after you use a recent build of eMember from here:
    http://support.tipsandtricks-hq.com/update-request

    Posted 1 year ago #
  3. hoffybalboa
    Member

    Did not help. I downloaded the latest plugin build. Uploaded. Deactivated and Reactivated the plugin. Same exact errors.

    I know you are swamped with other requests. I have a couple outstanding issues that i would be happy to pay for support to get completed.

    All the best,

    Bryan

    Posted 1 year ago #
  4. amin007
    Key Master

    I will send you an email to get site access so I can look at this.

    Posted 1 year ago #
  5. hoffybalboa
    Member

    Thanks Ivy. You solved my problem. Here is what happened for everyone else. They sent me the latest build of the plugin. I installed it. Deactivated and Reactivated the plugin. Cleared cache and the problem went away.

    Thanks everyone

    Posted 1 year ago #
  6. Ivy
    Administrator

    Hi, I am glad everything is working fine now. =)

    Posted 1 year ago #
  7. bastywebb
    Member

    I've been having trouble with this error too: Warning: array_keys() [function.array-keys]: The first argument should be an array in /home/themeove/public_html/wp-content/plugins/wp-eMember/wp_eMember1.php on line 76

    I am using eMember, Affiliate Platform and the eStore plugin. I have checked the option for creating wp users when someone registers via eMember. If I clear my browser cache the problem doesn't occur on the first login, but if I logout and then log back in the problem comes back.

    I did some testing and I think I have discovered the trigger but I'm not sure how best to solve the problem or interpret my findings - they seem contrary to my understanding of PHP variables. Here goes:

    On wp_eMember1.php, I added echo $user_id; above $_SESSION['user_id'] = $_POST['login_user_name']; around line 60 so it was now this:

    echo $user_id;
    $_SESSION['user_id'] = $_POST['login_user_name'];

    The echo statement returned the user ID value from the wp_users table as expected, which in this case was 4. I then moved the echo statement after the $_SESSION statement so it was this:

    $_SESSION['user_id'] = $_POST['login_user_name'];
    echo $user_id;

    Now, the echo statement returned member1, the value of $_SESSION['user_id']. This is what made me question my understanding of php - I didn't know that could happen. Regardless, because the value for $user_id changes to member1 instead of the wp_users table ID, the get_userdata($user_id); query doesn't return anything. This causes the Warning: array_keys() [function.array-keys]: The first argument should be an array in /home/themeove/public_html/wp-content/plugins/wp-eMember/wp_eMember1.php on line 76 (which in turn causes the cannot modify header info errors)

    So my question (finally) is how do I make sure that $user_id doesn't get reset somehow by the $_SESSION['user_id'] = $_POST['login_user_name'];

    Many Thanks

    Posted 1 year ago #
  8. amin007
    Key Master

    Please load a fresh build of WP eMember on your site from here:
    http://support.tipsandtricks-hq.com/update-request

    Please Post a link to your registration page after the update so I can signup a test member and log in to check it out.

    Posted 1 year ago #
  9. bastywebb
    Member

    Sure, the link to the registration page: http://themeover.com/register/

    I have activated the latest build now (6.2.9) from fresh. I also cleared my cache. As before, it works fine on first login after clearing the cache, but fails when logging out and then logging in a second time.

    Posted 1 year ago #
  10. amin007
    Key Master

    Something is not right... I will need to get site access so I can troubleshoot this. I will send you an email.

    Posted 1 year ago #

RSS feed for this topic

12Next »

Reply »

You must log in to post.

Tips and Tricks HQ  | WP Shopping Cart  | WP Affiliate Software  | WordPress Membership Plugin