0,0FlexyClown wrote:How many additional SQL queries does this perform?
0,0FlexyClown wrote:How many additional SQL queries does this perform?
It is 1 SQL query for every "poster" but the result is stored in the user cache. Hence for a known user no query is performed.FlexyClown wrote:How many additional SQL queries does this perform?
Code: Select all
get_user_rank($row['user_rank'], $row['user_posts'], $user_cache[$poster_id]['rank_title'], $user_cache[$poster_id]['rank_image'], $user_cache[$poster_id]['rank_image_src']);
Code: Select all
get_user_rank($row['user_rank'], $row['user_posts'], $user_cache[$poster_id]['rank_title'], $user_cache[$poster_id]['rank_image'], $user_cache[$poster_id]['rank_image_src']);
//added by Nyquist Show Groups Info
//check the system var:
if (isset($config['nyq_showgroupsinfo']))
{
//extract the groups
$nyq_groups_ranks_array = nyq_getgroupsarray($poster_id, $config['nyq_showgroupsinfo']);
$user_cache[$poster_id]['nyq_showgroupsinfo'] = $nyq_groups_ranks_array;
}
//end added by Nyquist Show Groups Info
Code: Select all
get_user_rank($row['user_rank'], $row['user_posts'], $user_cache[$poster_id]['rank_title'], $user_cache[$poster_id]['rank_image'], $user_cache[$poster_id]['rank_image_src']);
//added by Nyquist Show Groups Info
//check the system var:
if (isset($config['nyq_showgroupsinfo']))
{
//extract the groups
$nyq_groups_ranks_array = nyq_getgroupsarray_new($poster_id, $config['nyq_showgroupsinfo'],$user_cache[$poster_id]['rank_image_src']);
$user_cache[$poster_id]['nyq_showgroupsinfo'] = $nyq_groups_ranks_array;
}
//end added by Nyquist Show Groups Info
Will look at it when I've updated the mod (5-10 mins)FlexyClown wrote:Edited previous post to include this... but see you have already replied so next question
If user is a member of the default group, registered users, which has the default rank structure e.g.
0-10 posts = *
11 - 20 posts = **
21 - 30 posts = ***
etc and then a user is made a member of say, gold group, it is more than likely that you will have the gold group shown on the legend of logged on members with a separate legend colour to highlight this. Surely the member is going to want to reflect this by having a different coloured username in the legend, so they change their default group to gold group. The problem is now when you view posts from that user the default rank structure is no longer displayed as it is overwritten by the users default group rank. Surely the default rank group should still be displayed?
Obviously the way round this is to go to the user and set their rank to no special rank assigned. Now when viewing topics we have the default rank shown, the gold group rank shown and in the online user legend the user is shown as a member of gold group.
Make sense?!?
Last edited by FlexyClown on Mon Feb 04, 2008 11:20 am, edited 2 times in total. FlexyClown
Registered User
Very nice done!Nyquist wrote:FlexyClown I am not sure to get your point. I will be to that in a moment. Let me just first say that I solved the problem pointed out by RdJ1. Now there are no replications and the file linked in the first post has the new version of the MOD.
Also if you have yet installed the MOD than you can update quite easily.
...
Now that problem is fixed, when a user has a rank a his default rank, it isn't displayed in the groups-part of this mod!RdJ1 wrote:And something for the mod-writer:
When a user joins a group with a rank and he doesn't have his own special rank, his special rank will be set to the group-rank and than it will be displayed twice (one for the user, one for the group).
RdJ1 wrote:Will look at it when I've updated the mod (5-10 mins)FlexyClown wrote: ...
Will fix that, but because of a network-outage I lost my post (was allmost ready and then it was gone )Eelke wrote:I guess what FlexyClown is saying is that with this mod installed, the group rank for the default group should no longer replace the user's rank (that is what default phpBB 3 does, right? Haven't checked...), be that based on their post count or on a custom rank assignment. All the default group should do when this mod is installed is determine the color the user's name is displayed in.
That makes sense, since this mod now displays all rank-images for all groups a user is a member of anyway.
Nyquist, can I post this when i've done itRdJ1 wrote:And if Nyquist likes, I can post a tutorial here for displaying the group-ranks in profiles also.
Sure RdJ1, you're more than welcomeRdJ1 wrote:Nyquist, can I post this when i've done it
aaaaaall right, now i get it. Seems interesting. I will look into this. Just, i need some day to look for the proper piece of code to change. Of course any suggestion is welcome.Eelke wrote:I guess what FlexyClown is saying is that with this mod installed, the group rank for the default group should no longer replace the user's rank (that is what default phpBB 3 does, right? Haven't checked...), be that based on their post count or on a custom rank assignment. All the default group should do when this mod is installed is determine the color the user's name is displayed in.
That makes sense, since this mod now displays all rank-images for all groups a user is a member of anyway.
Ok thanks, will work at it tomorrow or Thursday. I have no time before then.Nyquist wrote:Sure RdJ1, you're more than welcomeRdJ1 wrote:Nyquist, can I post this when i've done it