<% ONLINE %>
Sly

Admin
6680
June 2002
|
 |
Mar. 29 2003,23:35 |
|
TITLE: Coloured group name in topic view AUTHOR: Sly
This hack makes the member group name in the topic view the same colour as the member group highlighting as set in the AdminCP.
------ Files needed:
cgi-bin/Sources/Topic.pm
------ Topic.pm
Find:
| Code Sample | $obj->{'POSTER'}->{'MEMBER_GROUP'} = $Topic::lang->{'m_group'}.' '.$obj->{'group_table'}->{ $obj->{'POSTER'}->{'MEMBER_GROUP'} }->{'TITLE'};
|
and change that to:
| Code Sample | my %format; for (split /\|/, $iB::INFO->{'AU_FORMAT'}) { /^(\d+)\~(.+?),(.+?)$/; $format{ $1 } = { ST => $2, END => $3 }; }
$obj->{'POSTER'}->{'MEMBER_GROUP'} = $Topic::lang->{'m_group'}.' '.$format{ $obj->{'POSTER'}->{'MEMBER_GROUP'} }->{ST}.$obj->{'group_table'}->{ $obj->{'POSTER'}->{'MEMBER_GROUP'} }->{'TITLE'}.$format{ $obj->{'POSTER'}->{'MEMBER_GROUP'} }->{END};
|
Save and upload
and you are done 
I AM AWAY FOR A WEEK (from 27 June) SO I WILL NOT BE AVAILIBLE FOR HACK SUPPORT DURING THIS TIME
[ iB Supported home ]
 If you are PMing me please link to the problem and please describe clearly why you are PMing
|
| Back to top |
|
|
Kage
Mmm, pie.. AHAHA pie..

Hacker
166
Nov. 2002
|
 |
Mar. 30 2003,03:13 |
|
indeed, my friend, indeed.
“A script is what you give the actors. A program is what you give the audience.” ~ Larry Wall #!/usr/bin/perl package Kage; my ${.02};
|
| Back to top |
|
|
Sly

Admin
6680
June 2002
|
 |
Mar. 30 2003,15:25 |
|
Oops my bad, I cut and pasted the wrong code, its fixed now
I AM AWAY FOR A WEEK (from 27 June) SO I WILL NOT BE AVAILIBLE FOR HACK SUPPORT DURING THIS TIME
[ iB Supported home ]
 If you are PMing me please link to the problem and please describe clearly why you are PMing
|
| Back to top |
|
|
dfb
iStopBy

Support Staff
175
Nov. 2002
|
 |
Mar. 30 2003,19:10 |
|
What a cool idea
|
| Back to top |
|
|
KiLLeR2001
wtf die²
Member
130
Dec. 2002
|
 |
Mar. 30 2003,19:25 |
|
| Quote (dfb @ Mar. 29 2003,14:10) | What a cool idea  |
Thanks
|
| Back to top |
|
|
wwfdisciple
Evil Commissioner
Adv.
569
Sep. 2002
|
 |
Mar. 31 2003,23:02 |
|
cool hack! adds some colour to an otherwise dreary factoid about a member
"If the Gods could build me a ladder to the heavens, I'd climb up the ladder and drop a big elbow on the world." -- Cactus Jack
http://www.wwfdisciples.ca/cgi-bin/ikon/ikonboard.cgi
|
| Back to top |
|
|
SKJain
BharatPremi

Support Staff
155
July 2002
|
 |
April 01 2003,15:43 |
|
Can this be done to Messenger view and Profile view too?
|
| Back to top |
|
|
Sly

Admin
6680
June 2002
|
 |
April 01 2003,16:20 |
|
Yes of course ...
for the messenger download:
cgi-bin/Sources/UserCP/MessView.pm
and find:
| Code Sample | $member->{'MEMBER_GROUP'} = $Messenger::lang->{'m_group'}.' '.$mem_group->{ $member->{'MEMBER_GROUP'} }->{'TITLE'};
|
and change that to:
| Code Sample | my %format; for (split /\|/, $iB::INFO->{'AU_FORMAT'}) { /^(\d+)\~(.+?),(.+?)$/; $format{ $1 } = { ST => $2, END => $3 }; }
$member->{'MEMBER_GROUP'} = $Messenger::lang->{'m_group'}.' '.$format{ $member->{'MEMBER_GROUP'} }->{ST}.$mem_group->{ $member->{'MEMBER_GROUP'} }->{'TITLE'}.$format{ $member->{'MEMBER_GROUP'} }->{END};
|
Save and upload
and for the Profile download:
cgi-bin/Sources/Profile.pm
and find:
| Code Sample | $member->{'MEMBER_GROUP'} = $obj->{'group_table'}->{ $member->{'MEMBER_GROUP'} };
|
and change that to:
| Code Sample |
my %format; for (split /\|/, $iB::INFO->{'AU_FORMAT'}) { /^(\d+)\~(.+?),(.+?)$/; $format{ $1 } = { ST => $2, END => $3 }; }
$member->{'MEMBER_GROUP'} = $Messenger::lang->{'m_group'}.' '.$format{ $member->{'MEMBER_GROUP'} }->{ST}.$obj->{'group_table'}->{ $member->{'MEMBER_GROUP'} }.$format{ $member->{'MEMBER_GROUP'} }->{END};
|
Save and upload
and you are done 
I AM AWAY FOR A WEEK (from 27 June) SO I WILL NOT BE AVAILIBLE FOR HACK SUPPORT DURING THIS TIME
[ iB Supported home ]
 If you are PMing me please link to the problem and please describe clearly why you are PMing
|
| Back to top |
|
|
dfb
iStopBy

Support Staff
175
Nov. 2002
|
 |
April 02 2003,01:09 |
|
Thanks for adding those, Sly!
|
| Back to top |
|
|
FireTraP
Dreamscape
Member
28
Feb. 2003
|
 |
June 17 2003,19:06 |
|
I've just tried installing this hack without any luck 
This is the error i got:
Ikonboard has exited with the following error:
Unrecognized character \xA0
This error was reported at: Sources/Topic.pm line 1162.
I am using 3.1.2a could that be the problem? If it is, does anyone know how to get this to work?
|
| Back to top |
|
|
Sly

Admin
6680
June 2002
|
 |
June 17 2003,19:34 |
|
Thats an error in your 'copying' skills, it means that your browser or text editor has converted the spaces in the code into 'unprintable characters'.
What are you using as a text editor?
I AM AWAY FOR A WEEK (from 27 June) SO I WILL NOT BE AVAILIBLE FOR HACK SUPPORT DURING THIS TIME
[ iB Supported home ]
 If you are PMing me please link to the problem and please describe clearly why you are PMing
|
| Back to top |
|
|
FireTraP
Dreamscape
Member
28
Feb. 2003
|
 |
June 17 2003,19:41 |
|
I think i've figured out how to sort it.. will try in a sec.
I'm using FlashFXP and editing it straight off the server without manualy downloading the files.. yeah the lazy mans way
Anyway it seems that even tho i had FlashFXP on "ascii upload only" in the preferances it was uploading my edits in binary for some reason.
I'll reply if its sorted
|
| Back to top |
|
|
FireTraP
Dreamscape
Member
28
Feb. 2003
|
 |
June 17 2003,19:48 |
|
Nah aint sorted... it would not let me upload in ascii for some reason so i changed the file extension to .txt uploaded in ascii then changed it back when it was on the server. Hit refresh and the problem was still there.
I used notepad to edit it.
|
| Back to top |
|
|
FireTraP
Dreamscape
Member
28
Feb. 2003
|
 |
June 17 2003,20:23 |
|
I downloaded Crimson editor and it still didn't work... after a bit of messing around I figured out the real problem though.
I'm using Opera browser and it seemed to be adding the extra characters when i copied the text.
Crimson editor looks cool though and i'm going to continue using it:)
Thanks for all your help guys.
|
| Back to top |
|
|
|
|