| Author |
Message |
sy_
Joined: 03 Aug 2006 Posts: 15
|
|
HIGHLIGHTED ADMIN & MEMBERS |
|
HEY ....... I DONT KNOW IF THIS IS ALREADY POSSIBLE WITH THIS SCRIPT ... but i think it would be cool if the admins or registered members name in comments would be highlighted to set them apart from the others who are not either an admin or member like on mad4milk >>>>http://mad4milk.net/entry/italy-won-the-world-cup
|
|
| Mon Aug 07, 2006 11:33 am |
|
 |
Guest
|
|
|
Please login to hide the ads.
|
|
|
|
 |
FI-DD
Admin

Joined: 22 Sep 2005 Posts: 2668 Location: Germany |
|
|
|
You can use $tpl['comment']['if-user'] in your template.
Make a if condition similar to the $tpl['comment']['if-right-have'] condition in the default template.
|
|
| Mon Aug 07, 2006 11:53 am |
|
 |
sy_
Joined: 03 Aug 2006 Posts: 15
|
|
|
|
ok i'll try to see if i can work that out ... thanks !
|
|
| Mon Aug 07, 2006 12:41 pm |
|
 |
sy_
Joined: 03 Aug 2006 Posts: 15
|
|
|
|
ok .... i understand what you suggested.... but i dont understand how you would set it up to get the color of the admins name on the comment to have a different color ..do you use only those 2 functions ???... sorry for my mis-understanding but do u think you could give an example ?
|
|
| Tue Aug 08, 2006 6:28 am |
|
 |
FI-DD
Admin

Joined: 22 Sep 2005 Posts: 2668 Location: Germany |
|
|
|
 |  | <? if ($tpl['comment']['if-user']){ ?>
<font color="red"><?=$tpl['comment']['author']; ?></font>
<? } else { ?>
<?=$tpl['comment']['author']; ?>
<? } ?> |
|
|
| Tue Aug 08, 2006 8:49 am |
|
 |
sy_
Joined: 03 Aug 2006 Posts: 15
|
|
|
|
oh well damm ... i thought of doin it that way but wasnt sure ... thanks again as usual fi-dd

|
|
| Tue Aug 08, 2006 9:05 am |
|
 |
sy_
Joined: 03 Aug 2006 Posts: 15
|
|
|
|
the code you gave me worked great !! but i have one last question and i'll stop buggin u ..... if i had two admins and wanted both to have a separate color what would i add ??
 |  |  |  | <? if ($tpl['comment']['if-user']){ ?>
<font color="red"><?=$tpl['comment']['author']; ?></font>
<? } else { ?>
<?=$tpl['comment']['author']; ?>
<? } ?> |
|
thanks again for all your help !
|
|
| Tue Aug 08, 2006 9:46 am |
|
 |
FI-DD
Admin

Joined: 22 Sep 2005 Posts: 2668 Location: Germany |
|
|
|
 |  | oh well damm ... i thought of doin it that way but wasnt sure |
Why not trying it? You can't break anything. The worst case is that it's not working.
 |  | if i had two admins and wanted both to have a separate color what would i add ?? |
 |  | if($tpl['comment']['author'] == "admin1"){
echo '<font style="color:red">'.$tpl['comment']['author'].'</font>';
}
elseif($tpl['comment']['author'] == "admin2"){
echo '<font style="color:blue">'.$tpl['comment']['author'].'</font>';
}
else {
echo $tpl['comment']['author'];
} |
|
|
| Tue Aug 08, 2006 7:20 pm |
|
 |
sy_
Joined: 03 Aug 2006 Posts: 15
|
|
|
|
well i wanted expert advice from a fellow german ...lol.... i already messed up strawberry once trying to change md5 into the sha1 & sha256 hash ... lol plus i was a little sleepy but once again as always thanks for ur help !
|
|
| Wed Aug 09, 2006 2:07 am |
|
 |
|