Bravo List
Register
Go Back   > Bravo List > Source Code > Trackers > TBDev
Reply
  #1  
Old 16-12-18, 21:56
elvira's Avatar
elvira elvira is offline
Senior Member
 
Join Date: Jan 2008
Slovenia
Posts: 106
Default Hit & Run mod
Here I have a HitRun but dont think if this work so need a help

announce.php have this

PHP Code:
    if ( isset( $self ) && $event == "stopped" ) {
        
mysql_query"DELETE FROM peers WHERE $selfwhere) or err"D Err" );
        if ( 
mysql_affected_rows() ) {
            
$updateset[] = ( $self["seeder"] == "yes" "seeders = seeders - 1" :
                
"leechers = leechers - 1" );
            
$res mysql_query"SELECT start_date, uploaded, downloaded FROM snatched WHERE torrentid = $torrent[id] AND userid = $userid) or
            
err"hitrun Err" ); //or err(mysql_error());
            
$snatched mysql_fetch_assoc$res );
            
$hitrun = ( ( $snatched["start_date"] > get_date_timegmtime() - 86400 ) && ( $snatched["downloaded"] / 1.00 ) > $snatched["uploaded"] ) ? "IF(hitrun = '0000-00-00 00:00:00', '" .
                
get_date_time() . "', hitrun)" "hitrun" );
            
mysql_query"UPDATE snatched SET ip = " sqlesc$ip ) . ", port = $port, connectable = '$connectable', uploaded = uploaded + $upthis, downloaded = downloaded + $downthis, to_go = $left, upspeed = $upspeed, downspeed = $downspeed$announcetime, last_action = '" .
                
get_date_time() . "', seeder = '$seeder', agent = " sqlesc$agent ) . ", hitrun = $hitrun WHERE torrentid = $torrentid AND userid = $userid) or err"SL Err 1" );
        }
    } elseif ( isset( 
$self ) ) {
        
$prev_action sqlesc$self['last_action'] );
        if ( 
$event == "completed" ) {
            
$updateset[] = "times_completed = times_completed + 1";
            
$finished ", finishedat = UNIX_TIMESTAMP()";
            
$finished1 ", complete_date = '" get_date_time() . "'";
        }

        
mysql_query"UPDATE peers SET ip = " sqlesc$ip ) . ", port = $port, connectable = '$connectable', uploaded = $uploaded, downloaded = $downloaded, to_go = $left, last_action = NOW(), prev_action = $prev_action, seeder = '$seeder', agent = " .
            
sqlesc$agent ) . $finished WHERE $selfwhere) or err"PL Err 1" );
        if ( 
mysql_affected_rows() ) {
            if ( 
$seeder <> $self["seeder"] )
                
$updateset[] = ( $seeder == "yes" ?
                    
"seeders = seeders + 1, leechers = leechers - 1" :
                    
"seeders = seeders - 1, leechers = leechers + 1" );
            
$anntime "timesann = timesann + 1";
            
mysql_query"UPDATE snatched SET ip = " sqlesc$ip ) . ", port = $port, connectable = '$connectable', uploaded = uploaded + $upthis, downloaded = downloaded + $downthis, to_go = $left, upspeed = $upspeed, downspeed = $downspeed$announcetime, last_action = '" .
                
get_date_time() . "', seeder = '$seeder', agent = " sqlesc$agent ) . $finished1$anntime WHERE torrentid = $torrentid AND userid = $userid) or
            
err"SL Err 2" );
        }
    } else {
        if ( 
$az["parked"] == "yes" )
            
err"Your account is parked! (Read the FAQ)" );
        elseif ( 
$az["downloadpos"] == "no" )
            
err"Your downloading priviledges have been disabled! (Read the rules)" );
        
mysql_query"INSERT INTO peers (torrent, userid, peer_id, ip, port, connectable, uploaded, downloaded, to_go, started, last_action, seeder, agent, downloadoffset, uploadoffset, passkey) VALUES ($torrentid$userid, " .
            
sqlesc$peer_id ) . ", " sqlesc$ip ) . ", $port,'$connectable', $uploaded$downloaded$left, NOW(), NOW(), '$seeder', " .
            
sqlesc$agent ) . ", $downloaded$uploaded, " sqlescunesc$passkey ) ) . ")" ) or
        
err"PL Err 2" );
        if ( 
mysql_affected_rows() ) {
            
$updateset[] = ( $seeder == "yes" "seeders = seeders + 1" :
                
"leechers = leechers + 1" );
            
$anntime "timesann = timesann + 1";
            
$hitrun "IF(hitrun > '" get_date_timegmtime() - 5400 ) . "', '0000-00-00 00:00:00', hitrun)";
            
$hitrunwarn "IF(hitrun > '" get_date_timegmtime() - 5400 ) . "', 'no', hitrunwarn)";
            
mysql_query"UPDATE snatched SET ip = " sqlesc$ip ) . ", port = $port, connectable = '$connectable', to_go = $left, last_action = '" .
                
get_date_time() . "', seeder = '$seeder', agent = " sqlesc$agent ) . ", $anntime, hitrun = $hitrun, hitrunwarn = $hitrunwarn WHERE torrentid = $torrentid AND userid = $userid) or
            
err"SL Err 3" );
            if ( !
mysql_affected_rows() && $seeder == "no" )
                
mysql_query"INSERT INTO snatched (torrentid, userid, peer_id, ip, port, connectable, uploaded, downloaded, to_go, start_date, last_action, seeder, agent) VALUES ($torrentid$userid, " .
                    
sqlesc$peer_id ) . ", " sqlesc$ip ) . ", $port, '$connectable', $uploaded$downloaded$left, '" .
                    
get_date_time() . "', '" get_date_time() . "', '$seeder', " sqlesc$agent ) . ")" ) or err"SL Err 4" );
}
}


userdetalis.php

PHP Code:
function snatchtable($res) {

$table "<table class=main border=1 cellspacing=0 cellpadding=5>
<tr>
<td class=colhead>Kategorija</td>
<td class=colhead>Torrent</td>
<td class=colhead>S.id</td>
<td class=colhead>Up.</td>
<td class=colhead>Rate</td>
<td class=colhead>Downl.</td>
<td class=colhead>Rate</td>
<td class=colhead>Ratio</td>
<td class=colhead>Akcija</td>
<td class=colhead>Zavrseno</td>
</tr>"
;

while (
$arr mysql_fetch_assoc($res)) {

$upspeed = ($arr["upspeed"] > mksize($arr["upspeed"]) : ($arr["seedtime"] > mksize($arr["uploaded"] / ($arr["seedtime"] + $arr["leechtime"])) : mksize(0)));
$downspeed = ($arr["downspeed"] > mksize($arr["downspeed"]) : ($arr["leechtime"] > mksize($arr["downloaded"] / $arr["leechtime"]) : mksize(0)));
$ratio = ($arr["downloaded"] > number_format($arr["uploaded"] / $arr["downloaded"], 3) : ($arr["uploaded"] > "Inf." "---"));
$id=$arr[id];
$table .= "<tr>
<td style='padding: 0px'><img src='pic/"
.htmlspecialchars($arr["catimg"])."' alt='".htmlspecialchars($arr["catname"])."' width=42 height=42></td>
<td><a href=details.php?id=
$arr[torrentid]><b>".(strlen($arr["name"]) > 50 substr($arr["name"], 050 3)."..." $arr["name"])."</b></a></td>
<td>"
.($arr["id"])."</td>
<td>"
.mksize($arr["uploaded"])."</td>
<td>
$upspeed/s</td>
<td>"
.mksize($arr["downloaded"])."</td>
<td>
$downspeed/s</td>
<td>
$ratio</td>
<td>"
.mkprettytime($arr["seedtime"] + $arr["leechtime"])."</td>
<td>"
.($arr["complete_date"] <> "0000-00-00 00:00:00" "<font color=green><b>Da</b></font>" "<font color=red><b>Ne</b></font>")."</td>
</tr>\n"
;
}
$table .= "</table>\n";

return 
$table;


and this userdetails too


PHP Code:
//=== start snatched
if (get_user_class() >= UC_MODERATOR){

if (
$_GET["snatched_table"]){
echo 
"<tr><td class=clearalt6 align=right valign=top><b>Snatched+</b><br>[ <a class=altlink href=\"userdetails.php?id=$id\" class=\"sublink\">Sakrij</a> ]</td><td class=clearalt6>";

$res mysql_query(
"SELECT UNIX_TIMESTAMP(sn.start_date) AS s, UNIX_TIMESTAMP(sn.complete_date) AS c, UNIX_TIMESTAMP(sn.last_action) AS l_a, UNIX_TIMESTAMP(sn.seedtime) AS s_t, sn.seedtime, UNIX_TIMESTAMP(sn.leechtime) AS l_t, sn.leechtime, sn.downspeed, sn.upspeed, sn.uploaded, sn.downloaded, sn.torrentid, sn.start_date, sn.complete_date, sn.seeder, sn.last_action, sn.connectable, sn.agent, sn.seedtime, sn.port, sn.ip, cat.name, cat.image, t.size, t.seeders, t.leechers, t.owner, t.name AS torrent_name ".
"FROM snatched AS sn ".
"LEFT JOIN torrents AS t ON t.id = sn.torrentid ".
"LEFT JOIN categories AS cat ON cat.id = t.category ".
"WHERE sn.userid=$id ORDER BY sn.start_date DESC"
) or die(mysql_error());

echo 
"<table border=1 cellspacing=0 cellpadding=3 align=center width=750><tr><td class=colhead align=center width=50>Type</td><td class=colhead align=left>Torrent</td>".
"<td class=colhead align=center>S. / L.</td><td class=colhead align=center>Up / Down</td><td class=colhead align=center>Size / Hr / Compl</td>".
"<td class=colhead align=center width=50>Ratio</td><td class=colhead align=center>Client</td></tr>";

while (
$arr mysql_fetch_assoc($res)){
$res2 mysql_query("SELECT seeder FROM peers WHERE torrent = $arr[torrentid] AND userid=$user[id]");
$arr2 mysql_fetch_assoc($res2);

//=======change colors
$count2= (++$count2)%2;
$class 'clearalt'.($count2==0?'6':'7');

//=== speed color red fast green slow ;)
if ($arr["upspeed"] > 0)
$ul_speed = ($arr["upspeed"] > mksize($arr["upspeed"]) : ($arr["seedtime"] > mksize($arr["uploaded"] / ($arr["seedtime"] + $arr["leechtime"])) : mksize(0)));
else
$ul_speed mksize(($arr["uploaded"] / ( $arr['l_a'] - $arr['s'] + )));
if (
$arr["downspeed"] > 0)
$dl_speed = ($arr["downspeed"] > mksize($arr["downspeed"]) : ($arr["leechtime"] > mksize($arr["downloaded"] / $arr["leechtime"]) : mksize(0)));
else
$dl_speed mksize(($arr["downloaded"] / ( $arr['c'] - $arr['s'] + )));

switch (
true){
case (
$dl_speed 600):
$dlc 'red';
break;
case (
$dl_speed 300 ):
$dlc 'orange';
break;
case (
$dl_speed 200 ):
$dlc 'yellow';
break;
case (
$dl_speed 100 ):
$dlc 'chartreuse';
break;
}

if (
$arr["downloaded"] > 0){
$ratio number_format($arr["uploaded"] / $arr["downloaded"], 3);
$ratio "<font color=" get_ratio_color($ratio) . "><b>Ratio:</b><br>$ratio</font>";
}
else
if (
$arr["uploaded"] > 0)
$ratio "Inf.";
else
$ratio "N/A";

$time mkprettytime(strtotime("now") - strtotime($arr["complete_date"]) - (($CURUSER["timezone"] + $CURUSER["dst"]) * 60));
$seedtime mkprettytime(strtotime("now") / 10800);
$days explode("d "$seedtime);
if(
sizeof($days) > 1) {
$seedtime   $arr["seedtime"] - $days[0];
}

//if ($time < 7 || $seedtime >= 259200)
if ($seedtime >= 86400)
$hr "<font color=green><b>Ne</b></font>";
else
$hr "<font color=red><b>Da</b></font>";

/// smallname torrents
$smallname3 =substr(htmlspecialchars($arr["torrent_name"]) , 048);
if (
$smallname3 != htmlspecialchars($arr["torrent_name"])) {
$smallname3 .= '...';
}

echo 
"<tr><td class=$class align=center>".($arr['owner'] == $id "<b><font color=orange>Torrent Owner</font></b><br><br>" "".($arr['complete_date'] != '0000-00-00 00:00:00' "<b><font color=green>Završeno</font></b><br><br>" "<b><font color=red>Ne Završeno</font><br><br>")."")."<img src=pic/$arr[image] alt=$arr[name]></td>".
"<td class=$class><a class=altlink href=details.php?id=$arr[torrentid]><b>$smallname3</b></a> ".($arr['complete_date'] != '0000-00-00 00:00:00' "<br>".
"<font color=silver>Početo: ".$arr['start_date']."</font><br><font color=silver>Završeno: ".$arr['complete_date']."</font>" "".
"<br><font color=silver>Početo: ".$arr['start_date']."</font><br><font color=orange>Akcija: ".$arr['last_action']."</font> ".
"".($arr['complete_date'] == '0000-00-00 00:00:00' "".($arr['owner'] == $id "" "[ ".mksize($arr["size"] - $arr["downloaded"])." i još do ]")."" "")."")."".($arr['complete_date'] != '0000-00-00 00:00:00' "<br>".
"".($arr['complete_date'] == '0000-00-00 00:00:00' "" "<font color=silver>Akcija: ".$arr['last_action']."</font>")."".
"<br><font color=silver>Vrijeme Downloada: ".($arr['leechtime'] != '0' mkprettytime($arr['leechtime']) : mkprettytime($arr['c'] - $arr['s'])."")."</font><br><font color=$dlc>[ Down. at: $dl_speed ]<font>".
"<br>" "<br>")."<font color=blue>".($arr['seedtime'] != '0' "Totalni Seed Vrijeme: ".mkprettytime($arr['seedtime'])." <font color=$dlc> " "Totalni Seed Vrijeme: N/A")."".
"</font><br><font color=green> [ Up. Speed: ".$ul_speed." ] </font>".($arr['complete_date'] == '0000-00-00 00:00:00' "<br><font color=$dlc>Download Speed: $dl_speed</font>" "")."".
"<br><font color=Green>Totalni Leech Vrijeme: ".mkprettytime($arr['leechtime'])."</font><br><font color=olive>Announced: ".($arr['timesann'])." puta</font><br><font color=orange>Leech Za: ".($arr['ip'])."</font></td>"."<td align=center class=$class>Se: ".$arr['seeders']."<br>Le: ".$arr['leechers']."</td><td align=center class=$class><font color=green>Up:<br>".
"<b>".$uploaded =mksize($arr["uploaded"])."</b></font><br><br><font color=orange>Down:<br><b>".$downloaded mksize($arr["downloaded"])."</b></font></td>".
"<td align=center class=$class>Veličina: ".mksize($arr["size"])."<br>Odvisno od: <font color=orange><b>".mksize($arr['size'] - $arr["downloaded"])."</b></font><br><br><b>Hit &amp; Run:</b> $hr<br><br><b>Završeno:</b><br>$time nazad</td>".
"<td align=center class=$class>$ratio<br><br>".($arr2['seeder'] == 'yes' "<font color=green><b>Seeduje</b></font>" "<font color=red><b>Ne Seeduje</b></font>")."".
"</td><td align=center class=$class>".$arr["agent"]."<br>Port: ".$arr["port"]."<br><br>".($arr["connectable"] == 'yes' "<b>Priključen: <font color=green>Da</font>".
"</b>" "<b>Priključen: <font color=red><b>Ne</b></font>")."</td></tr>\n";
}
echo 
"</table></td></tr>\n";
}
else
tr("<font color=orangered>Skinuti Torrenti:</font><br>","[ <a class=altlink href=\"userdetails.php?id=$id&snatched_table=1\" class=\"sublink\">Prikazi</a> ]  - $count_snatched <font color=red><b>staff jedino!!!</font></b>"1);
}
//=== end snatched 
cleanup.php

PHP Code:
function doautohitrun()
{
    global 
$SITENAME$CURUSER$DEFAULTBASEURL$autohitrun_interval$queries$query_stat;
    
set_time_limit(1200);
    
$result mysql_query("show processlist") or sqlerr(__FILE____LINE__);
    while (
$row mysql_fetch_array($result)) {
        if ((
$row["Time"] > 100) || ($row["Command"] == "Sleep")) {
            
$sql "kill " $row["Id"] . "";
            
mysql_query($sql) or sqlerr(__FILE____LINE__);
        }
    }
    
ignore_user_abort(1);
    
// Message users who have hit and run
    
$res mysql_query("SELECT s.id, userid, torrentid, name FROM snatched AS s INNER JOIN torrents AS t ON s.torrentid = t.id WHERE hitrun <> '0000-00-00 00:00:00' && hitrunwarn = 'no'") or sqlerr();
    if (
mysql_num_rows($res) > 0) {
        
$ids $userids = array();
        while (
$arr mysql_fetch_assoc($res)) {
            
$ids[] = $arr["id"];
            
$userids[] = $arr["userid"];
            
$hitrun[$arr["userid"]]++;
            
$torrents[$arr["userid"]] .= "\n[b][url=$DEFAULTBASEURL/details.php?id=$arr[torrentid]]$arr[name][/url][/b]";
        }
        
$userids array_unique($userids);
        foreach(
$userids as $userid) {
            
$msg sqlesc("It appears that you have hit and run on $hitrun[$userid] torrent" . ($hitrun[$userid] == "" "s") . ".\n\n We advise you to return to continue seeding " . ($hitrun[$userid] == "this" "these") . " torrent" . ($hitrun[$userid] == "" "s") . " within 1 hour or else you risk being warned, or if this happens to you regular you may even risk your account being disabled - If your a Donor you can choose to seed or not as donors wont be warned.\n\nThe torrent" . ($hitrun[$userid] == "" "s") . " on which you have been found hit and running on " . ($hitrun[$userid] == "is" "are") . ":\n$torrents[$userid]");
            
mysql_query("INSERT INTO messages (added, poster, sender, receiver, subject, msg) VALUES ('" get_date_time() . "', 0, 0, $userid, 'Hit and Run', $msg)") or sqlerr();
        }
        
mysql_query("UPDATE snatched SET hitrunwarn = 'pending' WHERE id IN (" implode(", "$ids) . ")") or sqlerr();
    }
    
// Process hit and runs of users that have not returned
    
$res mysql_query("SELECT id, userid FROM snatched WHERE hitrunwarn = 'pending' AND hitrun < '" get_date_time(gmtime() - 5400) . "'") or sqlerr();
    if (
mysql_num_rows($res) > 0) {
        
$ids $userids = array();
        while (
$arr mysql_fetch_assoc($res)) {
            
$ids[] = $arr["id"];
            
$userids[] = $arr["userid"];
            
$hitrun[$arr["userid"]]++;
        }
        
$userids array_unique($userids);
        foreach(
$userids as $userid)
        
mysql_query("UPDATE users SET hitruns = hitruns + $hitrun[$userid] WHERE id = $userid") or sqlerr();
        
mysql_query("UPDATE snatched SET hitrunwarn = 'yes' WHERE id IN (" implode(", "$ids) . ")") or sqlerr();
    }
    
// modified Warn repeating hit and runners
    
$maxhitrun 5;
    
$res mysql_query("SELECT id FROM users WHERE hitruns > $maxhitrun AND warned = 'no' AND class < " UC_VIP " AND immun='no'") or sqlerr();
    if (
mysql_num_rows($res) > 0) {
        
$userids = array();
        
$modcomment sqlesc(gmdate("d-m-Y") . " - Warned by System for Hit and Run.\n");
        
$msg sqlesc("You have continued to hit and run on torrents even after we have notified you. Therefore you have received a five day warning with your downloads disabled. You know when you sign up to a private community we rely on you following seedtime's so hopefully you will learn the system here :), and if you dont it may result in your account being disabled.");
        while (
$arr mysql_fetch_assoc($res)) {
            
$userids[] = $arr["id"];
            
mysql_query("INSERT INTO messages (added, poster, sender, receiver, subject, msg) VALUES ('" get_date_time() . "', 0, 0, $arr[id], 'Hit and Run', $msg)") or sqlerr();
        }
        
mysql_query("UPDATE users SET warned = 'yes', warneduntil = '" get_date_time(gmtime() + (86400)) . "', downloadpos = 'no', dlremoveuntil = '" get_date_time(gmtime() + (86400)) . "', modcomment = CONCAT($modcomment, modcomment), hitruns = 0 WHERE id IN (" implode(", "$userids) . ")") or sqlerr();
        
$count mysql_affected_rows();
        
write_log("Auto Hit And Run Cleanup: System warned and disabed download(s) from " $count " Member(s)");
        
write_log2("autohitrun""Auto Hit And Run Cleanup: System warned and disabed download(s) from " $count " Member(s)");
    }
    
// ==New remove expired warning and download disablement's for hit and run system
    
$res sql_query("SELECT id FROM users WHERE warned='yes' AND downloadpos='no' AND dlremoveuntil < NOW() AND dlremoveuntil <> '0000-00-00 00:00:00'") or sqlerr(__FILE____LINE__);
    
$msgs_buffer $users_buffer = array();
    if (
mysql_num_rows($res) > 0) {
        
$msg "Your downloads have been enabled and your warning removed. Please keep in your best behaviour from now on.\n";
        while (
$arr mysql_fetch_assoc($res)) {
            
$modcomment sqlesc(gmdate("Y-m-d H:i") . " - Downloads automatically enabled By System\n");
            
$msgs_buffer[] = '(0,' $arr['id'] . ',NOW(), ' sqlesc($msg) . ', \'Downloads enabled\')';
            
$users_buffer[] = '(' $arr['id'] . ',\'yes\',\'no\',\'0000-00-00 00:00:00\',\'0000-00-00 00:00:00\',' $modcomment ')';
        }
        if (
sizeof($msgs_buffer) > 0) {
            
sql_query("INSERT INTO messages (sender,receiver,added,msg,subject) VALUES " implode(', '$msgs_buffer)) or sqlerr(__FILE____LINE__);
            
sql_query("INSERT INTO users (id, downloadpos, warned, dlremoveuntil, warneduntil, modcomment) VALUES " implode(', '$users_buffer) . " ON DUPLICATE key UPDATE downloadpos=values(downloadpos),
    warned=values(warned),dlremoveuntil=values(dlremoveuntil),warneduntil=values(warneduntil),modcomment=concat(values(modcomment),modcomment)"
) or sqlerr(__FILE____LINE__);
            
$count mysql_affected_rows();
            
write_log("Delayed Cleanup: System enabled download(s) from " $count " Member(s)");
            
write_log2("autodewarn""Delayed Cleanup: System enabled download(s) from " $count " Member(s)");
        }
        unset (
$users_buffer);
        unset (
$msgs_buffer);
    }
    
// /////end hitrun script////////
    
write_log("----------------------Auto hit and run clean complete using $queries queries---------------------");
    
write_log2("autohitrun"" -------------------- Auto hit and run clean Complete using $queries queries --------------------");
    
// /////end hitrun script//////// 
Reply With Quote
  #2  
Old 16-12-18, 22:32
Tedmorris's Avatar
Tedmorris Tedmorris is offline
Senior Member
 
Join Date: Sep 2017
Posts: 36
Default
Change the time limit and download a torrent, stop seeding then do a forced cleanup and see if you have a H&R
Reply With Quote
  #3  
Old 16-12-18, 22:50
elvira's Avatar
elvira elvira is offline
Senior Member
 
Join Date: Jan 2008
Slovenia
Posts: 106
Default
if can someone post complete hitrun mod, my its not working
Reply With Quote
  #4  
Old 17-12-18, 02:31
Napon's Avatar
Napon Napon is offline
Senior Member
 
Join Date: Feb 2016
P2P
Posts: 324
Default
i do have a 08 hnr made by me buts its all mysqli PHP7 7.1
Reply With Quote
  #5  
Old 17-12-18, 14:51
elvira's Avatar
elvira elvira is offline
Senior Member
 
Join Date: Jan 2008
Slovenia
Posts: 106
Default
Can you post, please
Reply With Quote
  #6  
Old 17-12-18, 17:34
Napon's Avatar
Napon Napon is offline
Senior Member
 
Join Date: Feb 2016
P2P
Posts: 324
Default
Sorry No i would not doing that or ill be takeing code from my Source Code Click the image to open in full size.08 and i would not do that to get it you would need to have the full Source Code 08 from me and i would not upload it here as it took me alot of time to code it up and put new PHP7 7.1 on to it ...So sorry im not doing it
Reply With Quote
  #7  
Old 17-12-18, 17:38
darkalchemy's Avatar
darkalchemy darkalchemy is offline
VIP
 
Join Date: Dec 2017
United States
Posts: 62
Default
Quote:
Originally Posted by Napon View Post
Sorry No i would not doing that or ill be takeing code from my Source Code Click the image to open in full size.08 and i would not do that to get it you would need to have the full Source Code 08 from me and i would not upload it here as it took me alot of time to code it up and put new PHP7 7.1 on to it ...So sorry im not doing it
Then why would you tell someone that you have it?

It's like the asshole on the playground, "Na-na na-na na na!!"
__________________
I do custom coding, source installs, mods, server setup and/or config, etc. Feel free to pitch me your needs and your offer.
Reply With Quote
  #8  
Old 17-12-18, 17:39
Napon's Avatar
Napon Napon is offline
Senior Member
 
Join Date: Feb 2016
P2P
Posts: 324
Default
well what can i say
Reply With Quote
  #9  
Old 17-12-18, 18:00
elvira's Avatar
elvira elvira is offline
Senior Member
 
Join Date: Jan 2008
Slovenia
Posts: 106
Default
thank you @Napon you are very good person
Reply With Quote
  #10  
Old 19-12-18, 14:51
Elena's Avatar
Elena Elena is offline
Member
 
Join Date: Sep 2010
Ukraine
Posts: 7
Lightbulb Ban on racing if the rating is bad
Open announce.php and remove this code here:
Quote:
if ($az['class'] < UC_VIP) {
if ($use_wait) {
$gigs = $az['uploaded'] / (1024*1024*1024);
$elapsed = floor((strtotime(date('Y-m-d H:i:s')) - $torrent['ts']) / 3600);
$ratio = (($az['downloaded'] > 0) ? ($az['uploaded'] / $az['downloaded']) : 1);
if ($ratio < 0.5 || $gigs < 5)
$wait = 48;
elseif ($ratio < 0.65 || $gigs < 6.5)
$wait = 24;
elseif ($ratio < 0.8 || $gigs < 8)
$wait = 12;
elseif ($ratio < 0.95 || $gigs < 9.5)
$wait = 6;
else
$wait = 0;
if ($elapsed < $wait)
err('Not authorized (' . ($wait - $elapsed) . 'h) - READ THE FAQ!');
}
}
and two queries in the 153 default line from GIT, here it is:
Quote:
$rz = mysql_query('SELECT id, uploaded, downloaded, enabled, parked, class, passkey_ip FROM users WHERE passkey = '.sqlesc($passkey).' ORDER BY last_access DESC LIMIT 1') or err('Users error 1 (select)');
namely, uploaded, downloaded, since they are NOT NEEDED there anymore.

open download.php and everything before this request:

Quote:
sql_query("UPDATE torrents SET hits = hits + 1 WHERE id = ".sqlesc($id));
change to this:
Quote:
<?php
require_once("include/bittorrent.php");
dbconn();
loggedinorreturn();
parked();

if (@ini_get('output_handler') == 'ob_gzhandler' AND @ob_get_length() !== false)
{ // if output_handler = ob_gzhandler, turn it off and remove the header sent by PHP
@ob_end_clean();
header('Content-Encoding:');
}
$id = (int) $_GET["id"];
if (!is_numeric($id))
stderr($tracker_lang['error'],$tracker_lang['invalid_id']);
if ($use_wait)
if (($CURUSER["class"] < UC_POWER_USER) && $CURUSER) {
$gigs = $CURUSER["uploaded"] / (1024*1024*1024);
$ratio = (($CURUSER["downloaded"] > 0) ? ($CURUSER["uploaded"] / $CURUSER["downloaded"]) : 0);
if ($ratio < 0.5 || $gigs < 5) $wait = 48;
elseif ($ratio < 0.65 || $gigs < 6.5) $wait = 24;
elseif ($ratio < 0.8 || $gigs < 8) $wait = 12;
elseif ($ratio < 0.95 || $gigs < 9.5) $wait = 6;
else $wait = 0;
}
$res = mysql_query("SELECT name, filename, added, owner, banned FROM torrents WHERE id = ".sqlesc($id)) or sqlerr(__FILE__, __LINE__);
////////////////////////////////
$row = mysql_fetch_assoc($res);
if (!$row)
stderr($tracker_lang['error'], $tracker_lang['invalid_id']);
//////////////////////////////////
$name = $row['filename'];
$fn = "$torrent_dir/$id.torrent";
if (!$row || !is_file($fn) || !is_readable($fn))
stderr($tracker_lang['error'], $tracker_lang['unable_to_read_torrent']);
///////////////////
if ($row['banned'] == 'yes' && $row['owner'] != $CURUSER['id'] && get_user_class() < UC_MODERATOR)
stderr($tracker_lang['error'], 'Oops, and torrentik banned!');
///////////////////////////
if ($wait)
{
$elapsed = floor((gmtime() - strtotime($row["added"])) / 3600);
if ($elapsed < $wait)
{
$color = dechex(floor(127*($wait - $elapsed)/48 + 128)*65536);
stderr($tracker_lang['error'], "&nbsp;&nbsp;<nobr><font size="1" color="red">Raise the rating! You can download this release only through</font>&nbsp;<a href="faq.php#dl8"><font color="$color">".number_format($wait - $elapsed)." h</font></a></nobr><br>");
} }
////////////////////
Then play with the Details and Brows page, there you can paste the same code for the jump limit - close the download button and the message will be waiting for ** hours instead.
Reply With Quote
Reply

Tags
hit , hitrun , mod , run

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump



All times are GMT +2. The time now is 12:13. vBulletin skin by ForumMonkeys. Powered by vBulletin® Version 3.8.11 Beta 3
Copyright ©2000 - 2019, vBulletin Solutions Inc.