2011-06-07, 11:59 AM
2011-06-07, 12:01 PM
Are you using Username style plugin ?
2011-06-07, 12:02 PM
In ACP > Forums & Postings > Forum management. First check the Introduction category and look at the Moderators tab and see if the Guest usergroup was added there.
You might need to check the other forums as well the same way.
You might need to check the other forums as well the same way.
2011-06-07, 12:04 PM
(2011-06-07, 12:01 PM)Yaldaram Wrote: [ -> ]Are you using Username style plugin ?
yes, I'm Using that plugin
2011-06-07, 12:04 PM
Since many users are facing the issue that when they Install this plugin, then their Moderated By: "Some Username" becomes Moderated By: Guests
So here is how to resolve this issue;
Alright, Open plugin file and find;
and Change it into the following;
This should resolve the issue
No, that issue is coming from a plugin.
So here is how to resolve this issue;
Alright, Open plugin file and find;
function usernamestyle_build_forumbits_forum(&$forum)
{
global $db, $mybb, $lang, $templates, $moderatorcache, $modlistsetting;
// Moderator column is not off
$mybb->settings['modlist'] = $modlistsetting;
if($mybb->settings['modlist'] != 0)
{
$moderators = "";
$donemoderators = array();
$parentlist = explode(",", $forum['parentlist']);
foreach($parentlist as $fid)
{
if(is_array($moderatorcache[$fid]))
{
foreach($moderatorcache[$fid] as $moderator)
{
if(in_array($moderator['uid'], $donemoderators))
{
continue;
}
$moderator['username'] = format_name($moderator['username'], $moderator['usergroup'], $moderator['displaygroup']);
$moderator['profilelink'] = build_profile_link($moderator['username'], $moderator['uid']);
$moderators .= $comma;
$moderators .= $moderator['profilelink'];
$comma = ", ";
$donemoderators[] = $moderator['uid'];
}
}
}
$comma = "";
if($moderators)
{
eval("\$forum['modlist'] = \"".$templates->get("forumbit_moderators")."\";");
}
else
{
$forum['modlist'] = "";
}
}
// To avoid overwriting by original code segment
$mybb->settings['modlist'] = 0;
// Format lastposter name
$query = $db->simple_select("users", "usergroup, displaygroup", "uid = '".$forum['lastposteruid']."'");
$user = $db->fetch_array($query);
$forum['lastposter'] = format_name($forum['lastposter'], $user['usergroup'], $user['displaygroup']);
}
and Change it into the following;
function usernamestyle_build_forumbits_forum(&$forum)
{
global $db, $mybb, $lang, $templates, $moderatorcache, $modlistsetting;
// Moderator column is not off
$mybb->settings['modlist'] = $modlistsetting;
if($mybb->settings['modlist'] != 0)
{
$moderators = "";
$done_moderators = array(
"users" => array(),
"groups" => array()
);
$parentlistexploded = explode(',', $forum['parentlist']);
foreach($parentlistexploded as $mfid)
{
if(is_array($moderatorcache[$mfid]))
{
foreach($moderatorcache[$mfid] as $modtype)
{
foreach($modtype as $moderator)
{
if($moderator['isgroup'])
{
if(in_array($moderator['id'], $done_moderators['groups']))
{
continue;
}
$moderators .= $comma.htmlspecialchars_uni($moderator['title']);
$done_moderators['groups'][] = $moderator['id'];
}
else
{
if(in_array($moderator['id'], $done_moderators['users']))
{
continue;
}
$moderators .= "{$comma}<a href=\"".get_profile_link($moderator['id'])."\">".format_name(htmlspecialchars_uni($moderator['username']),$moderator['usergroup'],$moderator['displaygroup'])."</a>";
$done_moderators['users'][] = $moderator['id'];
}
$comma = ", ";
}
}
}
}
$comma = "";
if($moderators)
{
eval("\$forum['modlist'] = \"".$templates->get("forumbit_moderators")."\";");
}
else
{
$forum['modlist'] = "";
}
}
// To avoid overwriting by original code segment
$mybb->settings['modlist'] = 0;
// Format lastposter name
$query = $db->simple_select("users", "usergroup, displaygroup", "uid = '".$forum['lastposteruid']."'");
$user = $db->fetch_array($query);
$forum['lastposter'] = format_name($forum['lastposter'], $user['usergroup'], $user['displaygroup']);
}
This should resolve the issue
(2011-06-07, 12:02 PM)Aries-Belgium Wrote: [ -> ]In ACP > Forums & Postings > Forum management. First check the Introduction category and look at the Moderators tab and see if the Guest usergroup was added there.
You might need to check the other forums as well the same way.
No, that issue is coming from a plugin.
2011-06-07, 12:06 PM
(2011-06-07, 12:02 PM)Aries-Belgium Wrote: [ -> ]In ACP > Forums & Postings > Forum management. First check the Introduction category and look at the Moderators tab and see if the Guest usergroup was added there.
You might need to check the other forums as well the same way.
nope,no guest user group added there!!! look:
2011-06-07, 12:12 PM
Just make the edits which I've given above
2011-06-07, 12:18 PM
Thanks,
Rep You
Rep You
2011-06-07, 12:20 PM
No problem, glad your that error has been resolved using my modifications
2011-06-07, 12:34 PM
yes you are the best.