News:

Wondering if this will always be free?  See why free is better.

Main Menu

Member Color Link

Started by Nibogo, April 02, 2005, 06:32:51 AM

Previous topic - Next topic

ディン1031

Quote from: undysided on September 19, 2005, 04:02:54 PM
Quote
if(!empty($profile['member_group_color']) || !empty($profile['post_group_color']))
               $context['top_time_online'][$key]['link'] = '<a href="' . $scripturl . '?action=profile;u=' . $profile['ID_MEMBER'] . '" title="' . $txt[92] . ' ' . $profile['realName'] . '"><font color="'.(!empty($profile['member_group_color']) ? $profile['member_group_color'] : $profile['post_group_color']).'">' . $profile['realName'] . '</font></a>';
         }
      }
      if (!empty($modSettings['latestMember']) && !empty($modSettings['MemberColorLatestMember'])) {
         $profile = &$user_profile[$modSettings['latestMember']];
         if(!empty($profile['member_group_color']) || !empty($profile)['post_g']
              if (!empty($_REQUEST['expand']))
   {
      $month = (int) substr($_REQUEST['expand'], 4);
      $year = (int) substr($_REQUEST['expand'], 0, 4);

Hi,
I'm using 1.0.5 & I downloaded this mod today, I did it manually as whenever I tried the package manager it says the files are not for my version or corrupt. I downloaded MemberColorMod181a.tar.

I'm getting the error 'Parse error: parse error, unexpected '[' in /home/****/*****/Sources/Stats.php on line 381'

I copied from lines 375 - 385 & put it in the quote box

I'd be really grateful for help
Thanks :)

Hmmm the mod is not installed complete in the file... somehow theres a error ocour on the install.


<edit file>
$sourcedir/Stats.php
</edit file>

<search for>
$context['top_posters'][] = array(
'name' => $row_members['realName'],
'id' => $row_members['ID_MEMBER'],
'num_posts' => $row_members['posts'],
'href' => $scripturl . '?action=profile;u=' . $row_members['ID_MEMBER'],
'link' => '<a href="' . $scripturl . '?action=profile;u=' . $row_members['ID_MEMBER'] . '">' . $row_members['realName'] . '</a>'
);
</search for>

<add after>

if (!empty($modSettings['MemberColorStats']))
$MemberColor_ID_MEMBER[$row_members['ID_MEMBER']] = $row_members['ID_MEMBER'];
</add after>

<search for>
$context['top_starters'][] = array(
'name' => $row_members['realName'],
'id' => $row_members['ID_MEMBER_STARTED'],
'num_topics' => $row_members['hits'],
'href' => $scripturl . '?action=profile;u=' . $row_members['ID_MEMBER_STARTED'],
'link' => '<a href="' . $scripturl . '?action=profile;u=' . $row_members['ID_MEMBER_STARTED'] . '">' . $row_members['realName'] . '</a>'
);
</search for>

<add after>

if (!empty($modSettings['MemberColorStats']))
$MemberColor_ID_MEMBER[$row_members['ID_MEMBER_STARTED']] = $row_members['ID_MEMBER_STARTED'];
</add after>

<search for>
$context['top_time_online'][] = array(
'id' => $row_members['ID_MEMBER'],
'name' => $row_members['realName'],
'time_online' => $timelogged,
'seconds_online' => $row_members['totalTimeLoggedIn'],
'href' => $scripturl . '?action=profile;u=' . $row_members['ID_MEMBER'],
'link' => '<a href="' . $scripturl . '?action=profile;u=' . $row_members['ID_MEMBER'] . '">' . $row_members['realName'] . '</a>'
);
</search for>

<add after>

if (!empty($modSettings['MemberColorStats']))
$MemberColor_ID_MEMBER[$row_members['ID_MEMBER']] = $row_members['ID_MEMBER'];
</add after>

<search for>
foreach ($context['top_time_online'] as $i => $member)
$context['top_time_online'][$i]['time_percent'] = round(($member['seconds_online'] * 100) / $max_time_online);
</search for>

<add after>

if (!empty($modSettings['latestMember']) && !empty($modSettings['MemberColorLatestMember']))
$MemberColor_ID_MEMBER[$modSettings['latestMember']] = $modSettings['latestMember'];

//Yeah baby give me some colors =).
if (!empty($MemberColor_ID_MEMBER)) {
//Now Load the Missing global :)
global $user_profile;
loadMemberData($MemberColor_ID_MEMBER);
$cmemcolid = NULL;
if (!empty($modSettings['MemberColorStats'])) {
// First the Top Posters =)
foreach($context['top_posters'] as $key => $value) {
$cmemcolid = $context['top_posters'][$key]['id'];
$profile = &$user_profile[$cmemcolid];
if(!empty($profile['member_group_color']) || !empty($profile['post_group_color']))
$context['top_posters'][$key]['link'] = '<a href="' . $scripturl . '?action=profile;u=' . $profile['ID_MEMBER'] . '" title="' . $txt[92] . ' ' . $profile['realName'] . '"><font color="'.(!empty($profile['member_group_color']) ? $profile['member_group_color'] : $profile['post_group_color']).'">' . $profile['realName'] . '</font></a>';
}
// First the Top Starter =)
foreach($context['top_starters'] as $key => $value) {
$cmemcolid = $context['top_starters'][$key]['id'];
$profile = &$user_profile[$cmemcolid];
if(!empty($profile['member_group_color']) || !empty($profile['post_group_color']))
$context['top_starters'][$key]['link'] = '<a href="' . $scripturl . '?action=profile;u=' . $profile['ID_MEMBER'] . '" title="' . $txt[92] . ' ' . $profile['realName'] . '"><font color="'.(!empty($profile['member_group_color']) ? $profile['member_group_color'] : $profile['post_group_color']).'">' . $profile['realName'] . '</font></a>';
}
// First the Top Onliner =)
foreach($context['top_time_online'] as $key => $value) {
$cmemcolid = $context['top_time_online'][$key]['id'];
$profile = &$user_profile[$cmemcolid];
if(!empty($profile['member_group_color']) || !empty($profile['post_group_color']))
$context['top_time_online'][$key]['link'] = '<a href="' . $scripturl . '?action=profile;u=' . $profile['ID_MEMBER'] . '" title="' . $txt[92] . ' ' . $profile['realName'] . '"><font color="'.(!empty($profile['member_group_color']) ? $profile['member_group_color'] : $profile['post_group_color']).'">' . $profile['realName'] . '</font></a>';
}
}
if (!empty($modSettings['latestMember']) && !empty($modSettings['MemberColorLatestMember'])) {
$profile = &$user_profile[$modSettings['latestMember']];
if(!empty($profile['member_group_color']) || !empty($profile['post_group_color']))
$context['latest_member']['link'] = '<a href="' . $scripturl . '?action=profile;u=' . $profile['ID_MEMBER'] . '" title="' . $txt[92] . ' ' . $profile['realName'] . '"><font color="'.(!empty($profile['member_group_color']) ? $profile['member_group_color'] : $profile['post_group_color']).'">' . $profile['realName'] . '</font></a>';
}
}
</add after>



Bye
DIN1031
Support only via MOD Thread! NO PM Support!
My Forum: ayu][kult Forum
My Mods: My Small Mod Collection
My Parser: DIN1031's ModParser
Current Info: More away the next days, because i've to much work to do :x

Gary

Could you PM me the code so that I could install the mod manually on 1.1 RC 1 and so that I can install it manually onto Display.template.php only.
Gary M. Gadsdon
Do NOT PM me unless I say so
War of the Simpsons
Bongo Comics Fan Forum
Youtube Let's Plays

^ YT is changing monetisation policy, help reach 1000 sub threshold.

killerkraft

Greetings,

On 1.1 RC 1 it says that the mod has no install / uninstall options, so very hard to do all the code by hand.

If you could help just adding the install feature, would be nice.

KK

Elmacik

in 1.1 rc1 it gave too many errors (nearly all the executions)
i edited the mod and installation went well.. but i didnt see member colors change anywhere :P

btw, this mod is really organized very well. the author had thought everywhere that a member name would be shown. and we hope he update it for 1.1 rc 1 :) (i couldnt do myself)
Home of Elmacik

trenchteam

You need to set it up in the admin for it to appear!

Elmacik

omg, i deleted all fixes i did because i though its not working :(
where is admin panel?
Home of Elmacik

trenchteam

Should be in the forum admin, where you change the Karma and stuff.

ディン1031

#87
Finaly i've time to made a 1.1 RC1 Version (many many changes XD between 1.1 betas and 1.1 RC1)

Version: 1.85
This Version Work only in the 1.1RC1!

Did you have a older Version use 1.81a!

Bye
DIN1031
Support only via MOD Thread! NO PM Support!
My Forum: ayu][kult Forum
My Mods: My Small Mod Collection
My Parser: DIN1031's ModParser
Current Info: More away the next days, because i've to much work to do :x

huijaa

Do you mean SMF 1.1RC1... you descripted 1.0RC1...

Error at install step number 10:

./  // This looks weird, but it's because BoardIndex.php references the variable. $context['common_stats']['latest_member'] = array( 'id' => $modSettings['latestMember'], 'name' => $modSettings['latestRealName'], 'href' => $scripturl . '?action=profile;u=' . $modSettings['latestMember'], 'link' => '' . $modSettings['latestRealName'] . '', );  //Latest user need some colors... How could you put this into this file... i hate you... i hope no one read this :P if (!empty($modSettings['latestMember']) && !empty($modSettings['MemberColorLatestMember'])) { global $user_profile; loadMemberData($modSettings['latestMember']); $profile = &$user_profile[$modSettings['latestMember']]; if(!empty($profile['member_group_color']) || !empty($profile['post_group_color'])) $context['common_stats']['latest_member']['link'] = '' . $profile['realName'] . ''; } Themes/default/Calendar.template.php

And the rest is oke.
Dovenforum Nederland -- a forum for deaf people in the Netherlands --

ディン1031

Thx i totaly fogot to add the file XD

Thx
i replace the file in a few minutes :X

Bye
DIN1031
Support only via MOD Thread! NO PM Support!
My Forum: ayu][kult Forum
My Mods: My Small Mod Collection
My Parser: DIN1031's ModParser
Current Info: More away the next days, because i've to much work to do :x

trenchteam

yeah! BABY! THANKS DIN!! MANY THANKS FOR THIS UPDATE! ;D

ディン1031

So some people want colors in the SSI.php so i add some files for this (one for 1.05 and before and one for 1.1rc1).

This files are only writen for the SSI.php and also work without the normal install of the MemberColorLink mod :).

Bye
DIN1031
Support only via MOD Thread! NO PM Support!
My Forum: ayu][kult Forum
My Mods: My Small Mod Collection
My Parser: DIN1031's ModParser
Current Info: More away the next days, because i've to much work to do :x

Ryan

for some reason when i put this in my packages folder and view my package list so i cna install my mods...

The mod dont have a apply mod bit it doesnt show up as if its a new or old mod either any idear why?

its pretty wierd

thetzfreak

hey, useful mod! I downloaded and installed the rc1 version successfully... but can't find the option to turn it on. where is it?

ディン1031

#94
Quote from: thetzfreak on November 10, 2005, 10:25:37 PM
hey, useful mod! I downloaded and installed the rc1 version successfully... but can't find the option to turn it on. where is it?
Look into the Forum Settings. There is extra part for this :).

If not (or a empty part), which language do you use :x.
(or did you only install the ssi version *runs*, i hope not :x)

Quote from: M3THOD on November 10, 2005, 10:14:44 PM
for some reason when i put this in my packages folder and view my package list so i cna install my mods...

The mod dont have a apply mod bit it doesnt show up as if its a new or old mod either any idear why?

its pretty wierd
Hmmm some other version off this mod installed?
Forum Version 1.0.5? (Forum Version 1.0.5 only work with 1.81).

Bye
DIN1031
Support only via MOD Thread! NO PM Support!
My Forum: ayu][kult Forum
My Mods: My Small Mod Collection
My Parser: DIN1031's ModParser
Current Info: More away the next days, because i've to much work to do :x

Nightstalker

Need some help with this mod on a smf 1.05 board.Im [nofollow] only getting administrator and global moderator colours working.None of the members colours have changed;

DemonicInfluence

You are using the right version for 1.0.5. Right?   Also did u set a color for the other members in the membergroups part in the admin?

Nightstalker

#97
Everything is up to date except this file it seems.

Profile.template.php   1.0.1   1.0.4

Also I dint have any member groups assigned,so I see the problem now.
Is there anyway of changing the member user colours without having to create a user group.?

ディン1031

Quote from: Nightstalker on November 14, 2005, 05:25:41 AM
Everything is up to date except this file it seems.

Profile.template.php   1.0.1   1.0.4

Also I dint have any member groups assigned,so I see the problem now.
Is there anyway of changing the member user colours without having to create a user group.?
Yes, with the Post Releated group color =).

And look if alle changes of the templates are made and the options in the forum settings are checked :x (if they not checked they want work ;).

Bye
DIN1031
Support only via MOD Thread! NO PM Support!
My Forum: ayu][kult Forum
My Mods: My Small Mod Collection
My Parser: DIN1031's ModParser
Current Info: More away the next days, because i've to much work to do :x

John Slater

I get this annoying error when i try to upload the package to the package manager.

An Error Has Occurred!
The package you tried to upload either is not a valid package or has become corrupted. 


I have SMF 1.1 RC1 and i downloaded MemberColorMod185.tgz

I dont understand any ideas?

Advertisement: