Deaths Aprentice 0 Report post Posted February 16, 2005 Hello everyone, I created this mod a long time ago, back when i was till running an IPB. I've been running vB for a long time now, and forgot about this hack. Now, I've just found it here on my system, so i thought I'd share it . This hack was made for IPB version 1.2, I have not tested it on any other versions. However, I'm quite sure it will work on newer versions aswell. Ok, lets start. Download the required files here. Description of Mod: Show a bar in the topic and at the Memberlist 100% means a users has visit your board every day 0% means a user didn't visit your board yet (but he/she did sign up) Upload all direcories to the root of your forum Upload trap17_ipbmod.php to the place where index.php is and run it. Open sources\functions.php Find if (!$this->member['last_visit']) { // No last visit set, do so now! Add Above // activity mod | xgnews.tk $date_now = getdate($this->time_now);$date_last = getdate($this->member['last_activity']); if($date_now['year']!=$date_last['year'] or $date_now['mon']!=$date_last['mon'] or $date_now['mday'] != $date_last['mday']) { $DB->query("UPDATE trap17_ipbmembers SET activity=activity+1 WHERE id='".$this->member['id']."'"); } // activity mod | xgnews.tk Close & Save Open sources\Topics.php Find m.warn_level, m.warn_lastwarn, Add Directly After m.last_activity,m.activity, Find if ($row['author_id'] != 0) { Add Above $d_t=getdate(time());$d_m=getdate($row['joined']); $numofdays=(mktime(0,0,0,$d_t['mon'],$d_t['mday'],$d_t['year'])-mktime(0,0,0,$d_m['mon'],$d_m['mday'],$d_m['year']))/(24*60*60); $numofdays=round($numofdays);$activ=100; if($numofdays!=0) $activ = floor(100*($row['activity']/$numofdays)); if($activ >100) $activ=100; $row['acti']= "$activ% of max. days online"; $row['actip']= ($activ-1)."%"; Close & Save Open skin\s*\skin_topic.php Find {$author['member_joined']}<br /> Add Directly After {$author['acti']}<br /> <table width="100" border="0" cellspacing="0" cellpadding="0"><tr><td> <img src="html/bar/bxg.gif" width="{$author['actip']}" height="9" alt='bar' /><img src="html/bar/bxb.gif" width="1" height="9" alt='bar' /> </td></tr></table> Close & Save Open sources\Memberlist.php Find , me.photo_dimensions Add Directly After , m.activity Find $member['joined'] = $std->get_date( $member['joined'], 'JOINED' ); Add Above // activity mod | xgnews.tk $d_t=getdate(time());$d_m=getdate($member['joined']); $numofdays=(mktime(0,0,0,$d_t['mon'],$d_t['mday'],$d_t['year'])-mktime(0,0,0,$d_m['mon'],$d_m['mday'],$d_m['year']))/(24*60*60); $numofdays=round($numofdays); $activ=100; if($numofdays!=0) $activ = floor(100*($member['activity']/$numofdays)); if($activ >100) $activ=100; $member['acti']= "$activ%"; // activity mod | xgnews.tk Close & Save Open skin\s*\skin_mlist.php Find <th class='pformstrip' align="center" width="10%">{$ibforums->lang['member_group']}</th> Add Below <th class='pformstrip' align="center" width="5%">{$ibforums->lang['member_activ']}</th> Find <td class='row2' align="center" width="20%">{$member['group']}</td> Add Below <td class='row4' align="center" width="10%">{$member['acti']}</td> Find colspan="9" Replace with colspan="10" Find colspan="9" Replace with colspan="10" Find colspan="9" Replace with colspan="10" Close & Save Open lang\en\lang_mlist.php Find ); ?> Add Above member_activ => "Activity", Close & Save Open sources\Profile.php Find $info['joined'] = $std->get_date( $member['joined'], 'JOINED' ); Add below // activity mod | xgnews.tk $d_t=getdate(time());$d_m=getdate($member['joined']); $numofdays=(mktime(0,0,0,$d_t['mon'],$d_t['mday'],$d_t['year'])-mktime(0,0,0,$d_m['mon'],$d_m['mday'],$d_m['year']))/(24*60*60); $numofdays=round($numofdays); $activ=100; if($numofdays!=0) $activ = floor(100*($member['activity']/$numofdays)); if($activ >100) $activ=100; $info['acti']= "$activ%"; // activity mod | xgnews.tk Close & Save Open Skin\s*\skin_profile.php Find <tr> <td class="row3" valign='top'><b>{$ibforums->lang['joined']}</b></td> <td align='left' class='row1'><b>{$info['joined']}</b></td> </tr> Add below <tr> <td class="row3" valign='top'><b>{$ibforums->lang['act_mdo']}</b></td> <td align='left' class='row1' width="90%"><img src="html/bar/bxg.gif" width="{$info['acti']}" height="9" alt='bar' /><img src="html/bar/bxb.gif" width="1" height="9" alt='bar' /> {$info['acti']} </td> </tr> Close & Save Open lang\en\lang_profile.php Find ); ?> Add Above "act_mdo" => "max. days online", Close & Save Now re-upload all the files, and you're done! Share this post Link to post Share on other sites
FiReStOrM 0 Report post Posted February 16, 2005 nice tip .. thx Share this post Link to post Share on other sites
Deaths Aprentice 0 Report post Posted February 19, 2005 No problem .I have a very advanced version of this for vBulletin, maybe I'll code an advanced one for IPB some day... Share this post Link to post Share on other sites