Bad group assignement

Ghostrider
User w
User w
Posts: 8
Joined: Thu Sep 08, 2016 8:28 pm

Re: Bad group assignement

Post by Ghostrider »

Is there the same type of modification to avoid moderateur on phpbb to be included in editor author on Wp ?
thx
User avatar
axew3
w3all User
w3all User
Posts: 2883
Joined: Fri Jan 22, 2016 5:15 pm
Location: Italy
Contact:

Re: Bad group assignement

Post by axew3 »

Sorry can you repeat the question that i'm try to understand reading it, but maybe i've not got it

MOderators of phpBB, should not be added into WP as editor or author?
Ghostrider
User w
User w
Posts: 8
Joined: Thu Sep 08, 2016 8:28 pm

Re: Bad group assignement

Post by Ghostrider »

yes
my request is :
when phpbb moderator first connect on wp site, they must be assigned in Subscriber group not more
The forum organisation is not the same as the website organisation

On my old Phpbb forum i have 4 groups
- founder
- webmaster
- moderators
- subscribe

On my news WP site i want :

- founder >>>>>>> WP Administrator
- webmaster>>>>>> WP Editor
- moderators>>>>>> WP Subscriber
- subscribe >>>>>>> WP Subscriber

It ll be great to have the possibility to adjust this in the plugin seetings
aSpecialguest

Re: Bad group assignement

Post by aSpecialguest »

To change roles for users added from phpBB into WP in wp_w3all and you want custom configuration about this:
open phpbb_groups table on your phpBB database
Look for Group_Name field, related the group you want refer to.
So change as above explained, use the group name to check against before insert users into wordpress, into:
addons/ext_plugins_fixes.php file (1time)
and 2 times on class.wp.w3all-phpbb.php file

the code to search for on files is:
if ( $phpbb_user[0]->group_name == 'ADMINISTRATORS' ){

$role = 'administrator';

} elseif ( $phpbb_user[0]->group_name == 'GLOBAL_MODERATORS' ){

$role = 'editor';

.....
Just search for string ADMINISTRATORS, to get immediately these three portions of code (1time into ext_plugins_fixes.php and two times into class.wp.w3all-phpbb.php

All this about users permissions, could be coded to be friendly and changed with more easy, maybe in a single dedicated function?

[edited]
User avatar
axew3
w3all User
w3all User
Posts: 2883
Joined: Fri Jan 22, 2016 5:15 pm
Location: Italy
Contact:

Re: Bad group assignement

Post by axew3 »

yes of course, this was scheduled (and lost) time ago.
good point.
BorisO
Posts: 1
Joined: Mon Sep 05, 2016 8:04 pm
Location: Peru
Contact:

Re: Bad group assignement

Post by BorisO »

Major thanks for the article post. Awesome. Gatz
Post Reply