If you want a paperclip in the user line for the whos online window:
To add paperclip icon to whosonline listing
1. edit template whosonlinebit .
Insert the following code on the second line of the whosonline template.
<td bgcolor="#F1F1F1">$userinfo[portfolio]</td>
2. still editing template whosonline .
Search for "User". On the line above first occurance of "User" insert the following code.
<td bgcolor="#006633"><smallfont color="#FFCC00"><b>Portfolio</b></smallfont></td>
3. edit online.php source file.
search for the word: "onlinebit_ip"
the second occurance of this word you will see:
eval("\$onlinebit_ip = \"".gettemplate("whosonlinebit_ip")."\";");
}
Insert the following code on the line directly below the "}"
// Add a paperclip to the left of the username.
global $DB_site;
$count=$DB_site->query_first("
SELECT COUNT(*) AS 'count'
FROM viPortfolio
WHERE userid = ".$bbuserinfo['userid']."
AND enddate is NULL
");
if ( $count > 0 ) {
if ( $count > 1 )
$alt="Member ".$userinfo['username']." has ".$count['count']." portfolio attachments.";
else
$alt="Member ".$userinfo['username']." has ".$count['count']." portfolio attachment.";
$userinfo['portfolio'] = "<A HREF='portfolio.php?s=$session[sessionhash]&userid=".$userinfo['userid']."&action=view'>";
$userinfo['portfolio'] .= "<IMG BORDER=0 SRC='https://vborg.vbsupport.ru/greentek/paperclip.gif' ALT='".$alt."' TITLE='".$alt."'/></A>";
} else {
$userinfo['portfolio'] = 'N/A';
}
// Add a paperclip to the left of the username.
you are done.
|