Cannot save new Level

We cannot save a new level. We try to create, say Silver level. It says "Membership Level added" but never shows. We are on WP 3.12, latest Membership version, just downloaded.

We know the drill...disabled all plugins (including muplugins), uninstalled plugin, reinstalled plugin, changed theme to twentyten, etc. Still cannot add a new level.

Any ideas? Appreciate the help.

Thanks!

  • Scott

    I have nearly the same issue.

    My config is all free, no paid subscription. Visitor > Registered Level
    Buddypress is the subscription.

    New user signs up fine, activates fine. But no Level or Subscription are set. I can manually set the Level ok,,, but when I attempt to manually set the subscription it says it was successful. The "Edit Members" list still shows the user with no Subscription.

    Initially I found this in the error logs...

    [Thu May 05 07:03:05 2011] [error] [client 68.4.225.128] PHP Warning:  Invalid argument supplied for foreach() in /path/to/my/site.com/public_html/wp-content/plugins/membership/membershipincludes/classes/membershipadmin.php on line 5275, referer: http://sponsorgoal.com/wp-admin/admin.php?page=membershiplevels
    [Thu May 05 07:03:05 2011] [error] [client 68.4.225.128] PHP Warning:  Invalid argument supplied for foreach() in /path/to/my/site.com/public_html/wp-content/plugins/membership/membershipincludes/classes/membershipadmin.php on line 5288, referer: http://sponsorgoal.com/wp-admin/admin.php?page=membershiplevels
    [Thu May 05 07:03:47 2011] [error] [client 68.4.225.128] PHP Warning:  Invalid argument supplied for foreach() in /path/to/my/site.com/public_html/wp-content/plugins/membership/membershipincludes/classes/membershipadmin.php on line 5275, referer: http://sponsorgoal.com/wp-admin/admin.php?page=membershiplevels&msg=3
    [Thu May 05 07:03:47 2011] [error] [client 68.4.225.128] PHP Warning:  Invalid argument supplied for foreach() in /path/to/my/site.com/public_html/wp-content/plugins/membership/membershipincludes/classes/membershipadmin.php on line 5288, referer: http://sponsorgoal.com/wp-admin/admin.php?page=membershiplevels&msg=3

    Ivan had me replace line 5257
    $pings = $this->get_pings();
    ...and replace it with
    $pings = is_array( $this->get_pings() ) ? $this->get_pings() : array();

    This resolved the errors from appearing in the the apache logs. But didn't seem to fix any of the issues with the Levels and Subscriptions.

    In addition, I also found that the MySQL Db table "wp_m_membership_relationships" is not being populated with the "sub_id" , "expirydate" and "order_instance" as seen in the screenshot I've attached.

  • Scott

    By the way, I am running with Multi-DB WPMU

    After running this query against my database everything appears to be correct for that one user.

    UPDATE databasename.wp_m_membership_relationships SET sub_id = 1,
    expirydate = 2011-05-04 05:08:47,
    order_instance = 1 WHERE wp_m_membership_relationships.rel_id =25;

    Sooooo, somebody didn't get their coffee that morning and borked the function that inserts this into the db

    :smiley:

  • bmk0220

    Hi Phil,

    Thanks for the reply. Here's the latest.

    I left all of the plugins disabled, left the theme as twentyten, deleted the plugin 2.02, installed plugin 2.03 that was just released. Nothing, same problem.

    Then, it went to Repair Membership, ran verify tables, had several missing. Ran the repair tables and like magic it WORKED.

    I included a screenshot like you asked, but it only shows where it says "Membership Level added" and then you can see there isn't one. That's probably not any help, but does prove it can happen so maybe you can at least be aware of it.

    I think on several issues in the future, any users reading this, could verify the tables first and then run the repair.

    Hope this helps someone else.

    Thanks,
    Matt

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.