Deleting user error in mums

pennymachines
User www
User www
Posts: 72
Joined: Mon Feb 06, 2017 9:51 pm

Deleting user error in mums

Post by pennymachines »

Hi
Sorry again about my very delayed response to your last message on this subject. Life has been too complicated over the last couple of months...

In your last message you said,
axew3 wrote:In fact to test that it is the problem, if you change this part into actual code, on file /class.wp.w3all-phpbb.php

Code: Select all

   $w3all_config_db["dbhost"] = $dbc["w3all_phpbb_dbhost"];
   $w3all_config_db["dbport"] = $dbc["w3all_phpbb_dbport"];
   $w3all_config_db["dbname"] = $dbc["w3all_phpbb_dbname"];
   $w3all_config_db["dbuser"] = $dbc["w3all_phpbb_dbuser"];
   $w3all_config_db["dbpasswd"] = $dbc["w3all_phpbb_dbpasswd"];
   $w3all_config_db["table_prefix"] = $dbc["w3all_phpbb_dbtableprefix"];
assigning connection values manually, like so $w3all_config_db["dbname"] = 'my_db_name';
you'll see that the problem on deleting users on scenarios like your where i know the same happen (i've see the same into another mums) should result to be fixed.
I copied all the values from wp-w3all-config/config.php to the above code in class.wp.w3all-phpbb.php so it looks like this:

Code: Select all

   $w3all_config_db["dbhost"] = $dbc["localhost"];
   $w3all_config_db["dbport"] = $dbc[""];
   $w3all_config_db["dbname"] = $dbc["mywebsite_phpbb"];
   $w3all_config_db["dbuser"] = $dbc["mywebsite_phpbb"];
   $w3all_config_db["dbpasswd"] = $dbc["mypassword"];
   $w3all_config_db["table_prefix"] = $dbc["phpbb_"];
but saw exactly the same error:

Fatal error: Uncaught Error: Call to a member function get_results() on string in /home/www/mywebsite.com/wordpress/wp-content/plugins/wp-w3all-phpbb-integration/class.wp.w3all-phpbb.php:2067 Stack trace: #0 /home/www/mywebsite.com/wordpress/wp-content/plugins/wp-w3all-phpbb-integration/class.wp.w3all-phpbb.php(2114): WP_w3all_phpbb::wp_w3all_get_phpbb_user_info_by_email() #1 /home/www/mywebsite.com/wordpress/wp-content/plugins/wp-w3all-phpbb-integration/wp_w3all.php(1530): WP_w3all_phpbb::wp_w3all_phpbb_delete_user_signup() #2 /home/www/mywebsite.com/wordpress/wp-includes/class-wp-hook.php(326): w3all_wpmu_delete_user() #3 /home/www/mywebsite.com/wordpress/wp-includes/class-wp-hook.php(348): WP_Hook->apply_filters() #4 /home/www/mywebsite.com/wordpress/wp-includes/plugin.php(517): WP_Hook->do_action() #5 /home/www/mywebsite.com/wordpress/wp-admin/includes/ms.php(174): do_action() #6 /home/www/mywebsite.com/wordpress/wp-admin/network/users.php(186): wpmu_delete_user() #7 {main} thrown in /home/www/mywebsite.com/wordpress/wp-content/plugins/wp-w3all-phpbb-integration/class.wp.w3all-phpbb.php on line 2067
User avatar
axew3
w3all User
w3all User
Posts: 2809
Joined: Fri Jan 22, 2016 5:15 pm
Location: Italy
Contact:

Re: Deleting user error in mums

Post by axew3 »

Code: Select all

Uncaught Error: Call to a member function get_results() on string
mean that connection values are lost and the executed query fail.

Unfortunately i do not have an answer, the unique highly customized mums site i've see that was returning

Code: Select all

Uncaught Error: Call to a member function get_results() on string
on deleting an user
was about the fact that even the get_option() WordPress default function was returning an empty value (even on init) at deletion time on WP admin.
So i resolved the case directly adding values to the connection function at this time,
$w3all_config_db["dbname"] = "mywebsite_phpbb";
but would have work also as it is the code now, that retrieve the value via a direct default query when connection values are lost (get_option() return empty value) deleting an user on mums: but you say that even this do not work, that mean also that the default WP query fail some way for you. I do not have an answer to your question, i would like to reproduce so to reverse the problem but i cannot in any way i tested any mums it work fine. If you discover why into your still do not work even adding manual values, please let know! Thank you!
User avatar
ale
User w
User w
Posts: 16
Joined: Sun Jul 22, 2018 9:43 pm

Re: Deleting user error in mums

Post by ale »

Could you list plugins you are using?
User avatar
axew3
w3all User
w3all User
Posts: 2809
Joined: Fri Jan 22, 2016 5:15 pm
Location: Italy
Contact:

Re: Deleting user error in mums

Post by axew3 »

As last chance (and just to test the coming 2.8.5, which about this anyway come with the same exact unchanged code) i have try to reproduce the issue adding into wordpress MUMS an user which in phpBB the username has been changed like this
martinm- _yrick0_ and has been transferred via plugin's single user transfer (/wp-admin/tools.php?page=wp-w3all-users-to-wp) into wordpress, which into a default mums would be not ok because the username contains spaces and underscores: then WP, cannot create for these usernames a subsite, because the username contains chars not allowed and it is used for the blog name: but we assume that on these mums users are not allowed to create subsites then it is ok to use all allowed usernames chars, like it is for a default wp, so -0-9A-Za-z _.@
then i:
removed martinm- _yrick0_ from a blog, no error.
removed martinm- _yrick0_ from the main site, no error.
removed another username test directly from the main site, without removing before from a blog: no error.
ale wrote: Sat Jun 01, 2024 4:02 pm Could you list plugins you are using?
It would be a good idea to know the plugins list you're using so i could try to reproduce the issue.
pennymachines
User www
User www
Posts: 72
Joined: Mon Feb 06, 2017 9:51 pm

Re: Deleting user error in mums

Post by pennymachines »

OK, thank you both for your responses. I will try to focus on this now.
Unfortunately, the plugins are many (some I shall be removing, as no longer required).
Screen grab of my WP network admin plugins here.
Post Reply