• Hi everyone, I have to add a “Store Manager” user to my main site, but when I try to do it I get the following errors:

    Notice: Trying to get property ‘roles’ of non-object in / home / mbeshopp / public_html / wp-content / plugins / wpml-translation-management / classes / user / class-wpml-all-admins-to-translation-managers .php on line 40

    Warning: in_array () expects parameter 2 to be array, null given in / home / mbeshopp / public_html / wp-content / plugins / wpml-translation-management / classes / user / class-wpml-all-admins-to-translation- managers.php on line 40

    Notice: Trying to get property ‘user_login’ of non-object in /home/mbeshopp/public_html/wp-includes/ms-functions.php on line 1483

    Notice: Trying to get property ‘user_login’ of non-object in /home/mbeshopp/public_html/wp-includes/ms-functions.php on line 1500

    What can I do to solve the problem?

Viewing 7 replies - 16 through 22 (of 22 total)
  • Thread Starter igianni84

    (@igianni84)

    Yes, I running multisite… What do you mean by “non-multisite system”?

    I have tryed to disabled all plugin

    Moderator Samuel Wood (Otto)

    (@otto42)

    www.ads-software.com Admin

    Okay, I’m starting to see a sort of problem here.

    WordPress errore sul database ALTER command denied to user

    That error clarifies things a bit. It suggests that you are lacking ALTER permissions on your database.

    When you convert from a normal non-multisite install to a multisite one, then the users table is altered to have the new columns. Some plugins also create and alter tables, including apparently your store plugin.

    If you’re not allowed to alter tables, then this explains the various errors you’re getting. There’s no easy fix for this, you have bad permissions on the database. You’ll need to investigate why that is.

    Fixing this is a fairly technical problem that requires some knowhow. You may want to find somebody to do it for you if you’re not familiar with MySQL and such.

    Thread Starter igianni84

    (@igianni84)

    The problem on the permissions of the table I solved them, in fact as you can see from the last log I no longer have problems of permissions on the Alter Table.

    [21-Apr-2020 08:58:41 UTC] WordPress errore sul database Unknown column ‘spam’ in ‘field list’ per la query INSERT INTO wp_users (user_pass, user_nicename, user_email, user_url, user_registered, user_activation_key, display_name, user_login, spam) VALUES (‘$P$B.xxxxxxx’, ‘siriuxs’, ‘xxxxxxx’, ”, ‘2020-04-21 08:58:41’, ”, ‘siriuxs’, ‘siriuxs’, 0) fatta da wpmu_activate_signup, wpmu_create_user, wp_create_user, wp_insert_user
    [21-Apr-2020 08:58:41 UTC] WordPress errore sul database Unknown column ‘spam’ in ‘where clause’ per la query SELECT COUNT(ID) as c FROM wp_users WHERE spam = ‘0’ AND deleted = ‘0’ fatta da wpmu_activate_signup, wpmu_create_user, wp_create_user, wp_insert_user, do_action(‘user_register’), WP_Hook->do_action, WP_Hook->apply_filters, wp_maybe_update_network_user_counts, wp_update_network_user_counts
    [21-Apr-2020 08:58:41 UTC] PHP Notice: Trying to get property ‘user_login’ of non-object in /home/mbeshopp/public_html/wp-includes/ms-functions.php on line 1483
    [21-Apr-2020 08:58:41 UTC] PHP Notice: Trying to get property ‘user_login’ of non-object in /home/mbeshopp/public_html/wp-includes/ms-functions.php on line 1500
    [21-Apr-2020 08:58:41 UTC] WordPress errore sul database Unknown column ‘spam’ in ‘where clause’ per la query SELECT COUNT(ID) as c FROM wp_users WHERE spam = ‘0’ AND deleted = ‘0’ fatta da wpmu_activate_signup, wpmu_create_user, do_action(‘wpmu_new_user’), WP_Hook->do_action, WP_Hook->apply_filters, wp_maybe_update_network_user_counts, wp_update_network_user_counts
    • This reply was modified 4 years, 6 months ago by igianni84.
    • This reply was modified 4 years, 6 months ago by igianni84.
    Moderator Samuel Wood (Otto)

    (@otto42)

    www.ads-software.com Admin

    Yes, but if you didn’t have alter permissions when you first created your site and converted it to multisite, then it would not have been able to alter the users table to have the new fields.

    You may need to alter your users table manually. Back it up first, of course.

    Thread Starter igianni84

    (@igianni84)

    Okay, so I don’t quite understand what to do. Do I have to create the “spam” field or should I redo the installation of the multi-site? ??

    I had the same problem and I resolved it by adding two columns (“spam” and “deleted”) in wp_users:

    View post on imgur.com

    senathi

    (@senathi)

    @helud

    I had the same problem and your solution helped me..

    thank you.

Viewing 7 replies - 16 through 22 (of 22 total)
  • The topic ‘Unable to add new users’ is closed to new replies.