by axew3 » Thu Apr 26, 2018 6:24 pm
What happens is that users who register via Wordpress get created in phpBB with no group set.
Asking my self how it can happen
the
private static function create_phpBB_user($wpu){
on file
class.wp.w3all-phpbb.php
execute these inserts for users:
Code: Select all
$w3phpbb_conn->query("INSERT INTO ".$phpbb_config_file["table_prefix"]."user_group (group_id, user_id, group_leader, user_pending) VALUES ('2','$phpBBlid','0','0')");
$w3phpbb_conn->query("INSERT INTO ".$phpbb_config_file["table_prefix"]."user_group (group_id, user_id, group_leader, user_pending) VALUES ('7','$phpBBlid','0','0')");
$w3phpbb_conn->query("INSERT INTO ".$phpbb_config_file["table_prefix"]."acl_users (user_id, forum_id, auth_option_id, auth_role_id, auth_setting) VALUES ('$phpBBlid','0','0','6','0')");
i assume that by the way, this add the user into the mentioned defaults users groups, but maybe this is not true on your or some other case: strange because these are default not changeable groups in phpBB for what i know ...
you say these new wp users are added into phpBB and they results to not belong to any group: so it is also strange that after the result is that these users can see posts on widgets because the query, if no group isset for this user, should thrown error on mysql instruction inside functions that retrieve posts.
In case this user is inserted into these defaults groups, which into your phpBB as you have setup it, aren't considered?
On my tests it work, that not mean work in any case ... Little confused at moment by all the above...
[EDITED]
[quote]What happens is that users who register via Wordpress get created in phpBB with no group set.[/quote]
Asking my self how it can happen
the [i]private static function create_phpBB_user($wpu){[/i]
on file [i]class.wp.w3all-phpbb.php[/i]
execute these inserts for users:
[code] $w3phpbb_conn->query("INSERT INTO ".$phpbb_config_file["table_prefix"]."user_group (group_id, user_id, group_leader, user_pending) VALUES ('2','$phpBBlid','0','0')");
$w3phpbb_conn->query("INSERT INTO ".$phpbb_config_file["table_prefix"]."user_group (group_id, user_id, group_leader, user_pending) VALUES ('7','$phpBBlid','0','0')");
$w3phpbb_conn->query("INSERT INTO ".$phpbb_config_file["table_prefix"]."acl_users (user_id, forum_id, auth_option_id, auth_role_id, auth_setting) VALUES ('$phpBBlid','0','0','6','0')");[/code]
i assume that by the way, this add the user into the mentioned defaults users groups, but maybe this is not true on your or some other case: strange because these are default not changeable groups in phpBB for what i know ...
you say these new wp users are added into phpBB and they results to not belong to any group: so it is also strange that after the result is that these users can see posts on widgets because the query, if no group isset for this user, should thrown error on mysql instruction inside functions that retrieve posts.
In case this user is inserted into these defaults groups, which into your phpBB as you have setup it, aren't considered?
On my tests it work, that not mean work in any case ... Little confused at moment by all the above...
[size=130][EDITED][/size]