Member Color Link

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

Previous topic - Next topic

M@nNiak

Hi, i already install manually this mod, i edited every html archive like said in the instructions 

http://custom.simplemachines.org/mods/index.php?mod=111

but when i upload  and overwrite the old archives for the new ones already edited to the FTP, when i want to enter to  mysite/forum/index.php  appears a blank page , so idont know what is the problem because i follow every instruction well.

i´m using SMF 1.1.5. and the theme is Dark Fantasy

Hope you can help me and tell me what i´m doing bad or what happen.


thanks in advance.

ディン1031

Blank page is not normal... if you upload the old files it work normal?

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

M@nNiak

Quote from: ディン1031 on September 14, 2008, 09:57:59 AM
Blank page is not normal... if you upload the old files it work normal?

Bye
DIN1031

Yes, works normally whit the old files, but when i upload the new ones edited for this mod appears blank page.  i dont know what´s wrong.

i appreciate if you can help me.

ディン1031

#643
Why did you not install it with the package manager?

And are there any error on the error log, after you upload the old version? :)

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

General_Naga

When trying to install v3.0.5 onto SMF 2.0 b4 I get an error saying either the package is corrupt or does not support my version of SMF.

Any ideas?

ディン1031

Quote from: General_Naga on September 17, 2008, 03:50:03 AM
When trying to install v3.0.5 onto SMF 2.0 b4 I get an error saying either the package is corrupt or does not support my version of SMF.

Any ideas?
Hmmm i would say try to download the file again and overwrite it on the ftp.
I think something went wrong on you download, because i looked through the file, and see that the mod should 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

General_Naga

It works now, i just left it for a few hours and it was happy to install. No idea why must have just got confused.

Thanks for a great mod, I've been looking for something like this for a while!

TW1ST3D

Hi......

Downloaded and made the manual edits ......

BUT......

I get this error message when trying to open my forum:
Quote
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'FROM smf_log_online AS lo
LEFT JOIN smf_members AS mem ON (mem.ID_MEMBER = lo' at line 4
File: /home/galxc3/public_html/forum/Sources/BoardIndex.php
Line: 387
Any ideas on how to fix this?
Running 2.0 Gold.......SMF Rocks!!

ディン1031

Quote from: TW1ST3D on September 21, 2008, 06:54:57 PM
Hi......

Downloaded and made the manual edits ......

BUT......

I get this error message when trying to open my forum:
Quote
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'FROM smf_log_online AS lo
LEFT JOIN smf_members AS mem ON (mem.ID_MEMBER = lo' at line 4
File: /home/galxc3/public_html/forum/Sources/BoardIndex.php
Line: 387
Any ideas on how to fix this?
I think you make a mistake on this file ;).

But you can attach the file, and i can tell you how to fix it.

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

TW1ST3D

Running 2.0 Gold.......SMF Rocks!!

ディン1031

#650
Quote from: TW1ST3D on September 22, 2008, 05:39:47 AM
OK.........
File Attached,
You've delete a line on your change:

Your code is
lo.ID_MEMBER, lo.logTime, mem.realName, mem.memberName, mem.showOnline,
mem.birthdate as birthdate, mem.is_activated as is_activated,


This line is after that is missing:

mg.onlineColor, mg.ID_GROUP, mg.groupName


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

TW1ST3D

I just can't find that error.

I looked and found the line of code that you mention above, but it is correct.

Can you give me a line number on which the error occurs?
Running 2.0 Gold.......SMF Rocks!!

ディン1031

Sorry i see now what happen, i copied the wrong code together...

This is your code :)

lo.ID_MEMBER, lo.logTime, lo.url, mem.realName, mem.memberName, mem.showOnline,
mg.onlineColor, mg.ID_GROUP, mg.groupName, mem.birthdate as birthdate, mem.is_activated as is_activated,


And my mod normaly change it to :)


lo.ID_MEMBER, lo.logTime, mem.realName, mem.memberName, mem.showOnline,
mem.birthdate as birthdate, mem.is_activated as is_activated,
mg.onlineColor, mg.ID_GROUP, mg.groupName


If you change you code to this than it should work.

Line 330-333 ;).

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

TW1ST3D

Thanks for the Help !!  Seems to work fine Now !!
Running 2.0 Gold.......SMF Rocks!!

FireDitto

#654
Quote from: NS Lite on September 11, 2008, 07:03:31 AM
Hello.
First, sorry for my english.
Second, my forum work on 1.1.6 version.
When i want intall this great mod, i have a problem with  ./Sources/BoardIndex.php. Failure
What i must doing for mod work good?


I had that issue, too, but it also failed instead of skipping some of the languages.

I will try following your insturctions for NS Lite, but figured I should let you know, too.



5.   Execute Modification   ./Sources/BoardIndex.php   Test failed

18.   Execute Modification   ./Themes/default/languages/Modifications.english-utf8.php   Skipping file
19.   Execute Modification   ./Themes/default/languages/Modifications.german.php   Skipping file
20.   Execute Modification   ./Themes/default/languages/Modifications.german-utf8.php   Skipping file
21.   Execute Modification   ./Themes/default/languages/Modifications.spanish.php   Test failed
22.   Execute Modification   ./Themes/default/languages/Modifications.turkish.php   Test failed
23.   Execute Modification   ./Themes/default/languages/Modifications.turkish-utf8.php   Skipping file
24.   Execute Modification   ./Themes/default/languages/Modifications.dutch.php   Test failed


EDIT: Where do I go to make those changes?!

-noob'd-  >:( lol
Second Pass Weyr<br />An AU Pernse RPG<br /><br />SMF 2.0.6 with SP 2.3.5

ディン1031

Normal the skipping function work fine ;). But if you don't use this languages than you can ignore this.

The greater problem is the BoardIndex.php...

This are the changes for this:
Change in Filename: $sourcedir/BoardIndex.php
Quote
Search for this
if (!empty($row_board['ID_MODERATOR']))
{

Replace All with
if (!empty($row_board['ID_MODERATOR']))
{
//Color the Mods, too...
if(!empty($modSettings['MemberColorModeratorLinks'])) {
$context['MemberColor_ID_MEMBER'][$row_board['ID_MODERATOR']] = $row_board['ID_MODERATOR'];
$context['MemberColor_ModBoard'][$isChild ? $row_board['ID_PARENT'] : $row_board['ID_BOARD']] = array(
'bid' => ($isChild ? $row_board['ID_PARENT'] : $row_board['ID_BOARD']),
'cat' => $row_board['ID_CAT']
);
}

Search for this
'link' => $row_board['posterName'] != '' ? (!empty($row_board['ID_MEMBER']) ? '<a href="' . $scripturl . '?action=profile;u=' . $row_board['ID_MEMBER'] . '">' . $row_board['realName'] . '</a>' : $row_board['realName']) : $txt[470],

Replace All with
'link' => $row_board['posterName'] != '' ? (!empty($row_board['ID_MEMBER']) ? '<a href="' . $scripturl . '?action=profile;u=' . $row_board['ID_MEMBER'] . '">' . $row_board['realName'] . '</a>' : (!empty($modSettings['MemberColorGuests']) ? '<span style="color:'.$modSettings['MemberColorGuests'].';">' : '').$row_board['realName'].(!empty($modSettings['MemberColorGuests']) ? '</span>' : '')) : $txt[470],

Search for this
'start' => 'msg' . $row_board['new_from'],
'topic' => $row_board['ID_TOPIC']
);

Add after this
if (!empty($modSettings['MemberColorBoardindex']) && !empty($row_board['ID_MEMBER'])) {
$context['MemberColor_ID_MEMBER'][$row_board['ID_MEMBER']] = $row_board['ID_MEMBER'];
$MemberColor_board[$isChild ? $row_board['ID_PARENT'] : $row_board['ID_BOARD']] = array(
'bid' => ($isChild ? $row_board['ID_PARENT'] : $row_board['ID_BOARD']),
'cat' => $row_board['ID_CAT']);
}

Search for this
// Determine a global most recent topic.
if (!empty($row_board['posterTime']) && forum_time(true, $row_board['posterTime']) > $most_recent_topic['timestamp'])
$most_recent_topic = array(
'timestamp' => forum_time(true, $row_board['posterTime']),
'ref' => &$this_category[$isChild ? $row_board['ID_PARENT'] : $row_board['ID_BOARD']]['last_post'],
);
}
mysql_free_result($result_boards);

Add after this
//The latest member?
if (!empty($modSettings['latestMember']) && !empty($modSettings['MemberColorLatestMember']))
$context['MemberColor_ID_MEMBER'][$modSettings['latestMember']] = $modSettings['latestMember'];

// Know set the colors for the last post...
if (!empty($context['MemberColor_ID_MEMBER'])) {
$colorDatas = load_onlineColors($context['MemberColor_ID_MEMBER']);
$cmemcolid = null;

//So the BoardIndex need colored links
if (!empty($modSettings['MemberColorBoardindex']) && !empty($MemberColor_board))
foreach($MemberColor_board as $boardid_memcolor) {
$cmemcolid = $context['categories'][$boardid_memcolor['cat']]['boards'][$boardid_memcolor['bid']]['last_post']['member']['id'];
if(!empty($colorDatas[$cmemcolid]['colored_link']))
$context['categories'][$boardid_memcolor['cat']]['boards'][$boardid_memcolor['bid']]['last_post']['member']['link'] = $colorDatas[$cmemcolid]['colored_link'];
}

//You are not know what you do ;P Colors allready loaded :D
if(!empty($modSettings['MemberColorModeratorLinks']) && !empty($context['MemberColor_ModBoard'])) {
//This site will evertime use the correct Moderator Color, for this i need a extra query,
//because at the moment i don't know the correct color
$onlineColor = load_mod_color(true);
foreach($context['MemberColor_ModBoard'] as $boardid_memcolor) {
global $color_profile;
//Reset it :D
$context['categories'][$boardid_memcolor['cat']]['boards'][$boardid_memcolor['bid']]['link_moderators'] = array();
foreach($context['categories'][$boardid_memcolor['cat']]['boards'][$boardid_memcolor['bid']]['moderators'] as $moderators) {
$cmemcolid = $moderators['id'];
//Replace "Profil of" with "Moderator" ;D
$link = str_replace($txt[92], $txt[62], $colorDatas[$cmemcolid]['colored_link']);
if(empty($colorDatas[$cmemcolid]['online_color']) && !empty($onlineColor))
$link = '<a href="' . $scripturl . '?action=profile;u=' . $color_profile[$cmemcolid]['ID_MEMBER'] . '" title="' . $txt[62] . ' ' . $color_profile[$cmemcolid]['realName'] . '"'.(!empty($modSettings['MemberColorLinkOldSpanStyle']) ? '><span style="color:'.$onlineColor.';">' : ' style="color:'.$onlineColor.';">') . $color_profile[$cmemcolid]['realName'] . (!empty($modSettings['MemberColorLinkOldSpanStyle']) ? '</span>' : '').'</a>';
$context['categories'][$boardid_memcolor['cat']]['boards'][$boardid_memcolor['bid']]['moderators'][$cmemcolid]['link'] = $link;
//Create the new list...
$context['categories'][$boardid_memcolor['cat']]['boards'][$boardid_memcolor['bid']]['link_moderators'][] = $link;
}
}
}
}

Search for this
lo.ID_MEMBER, lo.logTime, mem.realName, mem.memberName, mem.showOnline,

Replace All with
lo.ID_MEMBER, lo.logTime, mem.realName, mem.memberName, mem.showOnline,
mem.birthdate as birthdate, mem.is_activated as is_activated,

Search for this
$context['num_users_hidden']++;
continue;
}

Replace All with
$context['num_users_hidden']++;
continue;
}
//Happy Birthday Color ;D Hope you love it :D
if(!empty($modSettings['MemberColorBirthdayColor']) && !empty($row['birthdate']) && compare_colorBirthdate($row['birthdate']))
$row['onlineColor'] = $modSettings['MemberColorBirthdayColor'];
//Color Banned user, replace there color...?
if(!empty($modSettings['MemberColorBanned']) && isset($row['is_activated']) && $row['is_activated'] >= 10)
$row['onlineColor'] = $modSettings['MemberColorBanned'];


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

FireDitto

Okay... but where do I go to make those changes? I cannot for the life of me figure that bit out!!
Thanks ><
Second Pass Weyr<br />An AU Pernse RPG<br /><br />SMF 2.0.6 with SP 2.3.5

ディン1031

Change in Filename: $sourcedir/BoardIndex.php
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

gizmo28

Hi, I got this mod installed  with no problem using the Package manager. But I get this error in my log a lot.


http://*************/index.php? 
2: mysql_free_result(): 35 is not a valid MySQL result resource
File: /home/*****/public_html/Sources/Subs-Calendar.php
Line: 175 


I manually double checked the edits and they are all there and correct

ディン1031

Quote from: gizmo28 on September 25, 2008, 11:02:52 PM
Hi, I got this mod installed  with no problem using the Package manager. But I get this error in my log a lot.


http://*************/index.php? 
2: mysql_free_result(): 35 is not a valid MySQL result resource
File: /home/*****/public_html/Sources/Subs-Calendar.php
Line: 175 


I manually double checked the edits and they are all there and correct
This is strange, i think this is not from my mod, because my mod have only one standard query in the load.php so i assume there is an other error ;).

Can you attach your Subs-Calendar.php?

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

Advertisement: