Login
Username: Password:
Remember me

[Sign Up] / [Recover Password]

Theme / Language

Popular
New Torrents
new name
Size: 18.40 MB
Most active
new name
S: 74 L: 3
New Posters
User Posts

Go to Profile

TTv3 Micro Edition — 2021-02-17 20:00:05 in v3 Download
thanks for the share   :)
for any bbcode you do not have in format_comment function just remove from this line
for standard v3 i think it should be something like this
replace
//toolbar: 'bold,italic,underline,strike,left,center,right,font,size,color,cut,copy,paste,code,quote,image,link,emoticon,youtube,source',


for

toolbar: 'bold,italic,underline,strike,left,center,right,font,size,color,cut,copy,paste,quote,image,link,emoticon,youtube,source',
yes thats looks fine :thum
This line commented out

//toolbar: 'bold,italic,underline,strike,left,center,right,font,size,color,cut,copy,paste,code,quote,image,link,emoticon,youtube,source',



Only code, needs removing all the other bbcode should work

Nice function not sure why header didnt work was it below all other js - doesnt really matter as long as its working
Only thing i think i am missing is the edit post part where the db contents need echoing into post which should look like this
<textarea  id='example' style='height:300px;width:100%;' name='body' rows='13'><?php echo htmlspecialchars($body) ?></textarea>


for smileys to keep old post intact i have added a second array still looking at how to add more

in functions.php find
function format_comment($text)
{
   global $smilies;


replace with global line with
global $smilies, $smilies1;



find
    reset($smilies);
   while (list($code, $url) = thisEach($smilies)) {
       $s = str_replace($code, '<img border="0" src="' .  $site_config['SITEURL'] . '/assets/images/smilies/' . $url . '" alt="' . $code . '" title="' . $code . '" />', $s);
   }


add below
 

   reset($smilies1);
   while (list($code, $url) = thisEach($smilies1)) {
       $s = str_replace($code, '<img border="0" src="' . $site_config['SITEURL'] . '/sceditor/' . $url . '" alt="' . $code . '" title="' . $code . '" />', $s);
   }


in backend smilies.php add new array under old one

$smilies1 = array
   (
":)" => "emoticons/smile.png",
":angel:" => "emoticons/angel.png",
":angry:" => "emoticons/angry.png",
"8-)" => "emoticons/cool.png",
":'(" => "emoticons/cwy.png",
":ermm:" => "emoticons/ermm.png",
":D" => "emoticons/grin.png",
"<3" => "emoticons/heart.png",
":(" => "emoticons/sad.png",
":O" => "emoticons/shocked.png",
":P" => "emoticons/tongue.png",
";)" => "emoticons/wink.png",
":alien:" => "emoticons/alien.png",
":blink:" => "emoticons/blink.png",
":blush:" => "emoticons/blush.png",
":cheerful:" => "emoticons/cheerful.png",
":devil:" => "emoticons/devil.png",
":dizzy:" => "emoticons/dizzy.png",
":getlost:" => "emoticons/getlost.png",
":happy:" => "emoticons/happy.png",
":kissing:" => "emoticons/kissing.png",
":ninja:" => "emoticons/ninja.png",
":pinch:" => "emoticons/pinch.png",
":pouty:" => "emoticons/pouty.png",
":sick:" => "emoticons/sick.png",
":sideways:" => "emoticons/sideways.png",
":silly:" => "emoticons/silly.png",
":sleeping:" => "emoticons/sleeping.png",
":unsure:" => "emoticons/unsure.png",
":woot:" => "emoticons/w00t.png",
":wassat:" => "emoticons/wassat.png",
":whistling:" => "emoticons/whistling.png",
":love:" => "emoticons/wub.png",
);


in header.php find this line and remove code, from this line that should now fully work with v3
toolbar: 'bold,italic,underline,strike,left,center,right,font,size,color,cut,copy,paste,code,quote,image,link,emoticon,youtube,source',
A copy of my editor mod for v3 - in progress because some bbcode/smilies might need adding to format comment but this is easy to add afterwards just need some testers to finish this off
and here is the docs https://www.sceditor.com/documentation/options/

header.php with the other linked css stuff
<link rel="stylesheet" href="sceditor/minified/themes/default.min.css" id="theme-style" />


Add the js
    <script src="sceditor/minified/sceditor.min.js"></script>
<script src="sceditor/minified/icons/monocons.js"></script>
<script src="sceditor/minified/formats/bbcode.js"></script>



this line needs to go underneath the above code or below all the js links
<script>
// Replace the textarea #example with SCEditor
var textarea = document.getElementById('example');
sceditor.create(textarea, {
format: 'bbcode',
style: 'minified/themes/content/default.min.css',
 startInSourceMode: true,
 toolbar: 'bold,italic,underline,strike,left,center,right,font,size,color,cut,copy,paste,code,quote,image,link,emoticon,youtube,source',
 emoticonsRoot: "<?php echo $site_config['SITEURL'] ?>/sceditor/",
 emoticonsCompat: true
});
</script>


Please take note in the last piece of code we use example to link (textarea var textarea = document.getElementById('example');)
so all textareas with the editor need to be tagged/id with example

This is a example of forum if you search forum.php for textbbcode("Form", "body"); there is 2
And replace with
<textarea  id='example' style='height:300px;width:80%;' name='body' rows='13'></textarea>


There is one textbbcode("Form", "body"); in insert_compose_frame() as well
ill go through smilies and some bbcode later to finish this off


Finally add folder sceditor to root
Torrent Test — 2021-01-25 19:21:43 in M-BiTsy Support
seems to be encoding causing issues
Uncaught Exception: 2021-01-25 19:10:44 - SQLSTATE[22007]: Invalid datetime format: 1366 Incorrect string value: '\xB3v&\xED\xB5u...' for column peer_id

i removed the peer_id hash and now i get errors on rutorrent just need to get colleration on database right now
Torrent Test — 2021-01-25 18:59:39 in M-BiTsy Support
i dont use imdb mate so you can turn off in config. but in the example https://torrenttrader.uk/torrents/read?id=1
i just removed like from database which switches to normal view

Maksimum, did you use download or magnet - for first download must be download not magnet to add passkey

just seems to be rtorrent having issues, ill keep playing with it @storrents can you post a updated copy of yours
Torrent Test — 2021-01-23 05:05:44 in M-BiTsy Support
looking through the announce log and the only thing i can see wrong is the start column gets reset every time thats fixed,
been working on announce for ages bit by bit im surprised the v3 one works lol theres so many errors
like the connectable code should return bool not sure if that will throw big error in php 8  i used your function for that  :thum

been testing on multiple trackers and the only headache was utorrent thats because on the peer_id having dots in u455.g45.454  had to use hex2bin to format and seems to work
in peer table its hex2bin (like hash) so on announce response to client it sends that not the proper peer_id but seems to work flawless - the client can read info_hash so i asume it can for peer_id

any suggestions on collation on the column im using ut8mb84blah general ci - i know changing db engine would fix this but looking for something is MyISAM

the announce (one bencode function cause we hate it  :rofl )
<?php
// Error Reporting
ini_set('display_errors', 0);
ini_set('display_startup_errors', 0);
error_reporting(0);
ini_set('error_log', '../data/logs/errors_log.txt');
ignore_user_abort(true);
require '../app/config/config.php';
require '../app/libraries/Database.php';
require '../app/models/Logs.php';
require '../app/libraries/TimeDate.php';
// Register custom exception handler
include "../app/helpers/exception_helper.php";
set_exception_handler("handleUncaughtException");
// Used for testing
define('__INTERVAL', 60);
define('__TIMEOUT', 120);

//Do some input validation
function valdata($g, $fixed_size = false)
{
   if (!isset($_GET[$g])) {
       die(track('Invalid request, missing data'));
   }
   if (!is_string($_GET[$g])) {
       die(track('Invalid request, unknown data type'));
   }
   if ($fixed_size && strlen($_GET[$g]) != 20) {
       die(track('Invalid request, length on fixed argument not correct'));
   }
   if (strlen($_GET[$g]) > 80) { //128 chars should really be enough
       die(track('Request too long'));
   }
}

function isConnectable($ipadress, $port) {
   $fp = @fsockopen($ipadress, $port, $errno, $errstr, 0.1);
   if (!$fp) {
       return false;
   } else {
       fclose($fp);
       return true;
   }
}

function gmtime()
{
   return strtotime(get_date_time());
}

function get_date_time($timestamp = 0)
{
   if ($timestamp) {
       return date("Y-m-d H:i:s", $timestamp);
   } else {
       return gmdate("Y-m-d H:i:s");
   }
}


//Bencoding function, returns a bencoded dictionary (You may go ahead and enter custom keys in the dictionary)
function track($list, $c = 0, $i = 0)
{
   if (is_string($list)) { //Did we get a string? Return an error to the client
       return 'd14:failure reason' . strlen($list) . ':' . $list . 'e';
   }
   $p = ''; //Peer directory
   foreach ($list as $d) { //Runs for each client
       $pid = '';
       if (!isset($_GET['no_peer_id'])) { //Send out peer_ids in the reply
           $real_id = hex2bin($d[2]);
           $pid = '7:peer id' . strlen($real_id) . ':' . $real_id;
       }
       $p .= 'd2:ip' . strlen($d[0]) . ':' . $d[0] . $pid . '4:porti' . $d[1] . 'ee';
   }
   //Add some other paramters in the dictionary and merge with peer list
   $r = 'd8:intervali' . __INTERVAL . 'e12:min intervali' . __INTERVAL . 'e8:completei' . $c . 'e10:incompletei' . $i . 'e5:peersl' . $p . 'ee';
   return $r;
}


// Use the correct content-type
header("Content-type: Text/Plain");

// Make sure we have something to use as a passkey
$passkey = $_GET['passkey'] ?? '';
// Standard Information Fields
$info_hash = bin2hex($_GET['info_hash']);
$peerid = bin2hex($_GET['peer_id']);
$port = intval($_GET['port']);
$downloaded = isset($_GET['downloaded']) && is_numeric($_GET['downloaded']) ? intval($_GET['downloaded']) : 0;
$uploaded = isset($_GET['uploaded']) && is_numeric($_GET['uploaded']) ? intval($_GET['uploaded']) : 0;
$left = isset($_GET['left']) && is_numeric($_GET['uploaded']) ? intval($_GET['left']) : 0;
$seeder = ($left == 0) ? "yes" : "no";
$user_agent = isset($_SERVER['HTTP_USER_AGENT']) && is_string($_SERVER['HTTP_USER_AGENT']) ? substr($_SERVER['HTTP_USER_AGENT'], 0, 80) : "N/A";
$ipadress = is_string($_SERVER['REMOTE_ADDR']) ? $_SERVER['REMOTE_ADDR'] : die("Weird ip adress");
$event = $_GET['event'] ?? '';
// Extra Information Fields
$no_peer_id = $_GET["no_peer_id"];
$compact = ($_GET["compact"] && $_GET["compact"] == 1) ? true : false;
$numwant = $_GET["numwant"] ? (int) $_GET["numwant"] : PEERLIMIT;

// Inputs that are needed, do not continue without these
valdata('peer_id', true);
valdata('port');
valdata('info_hash', true);
// Do we have a valid client port, support compact, is a browser?
if (!ctype_digit($_GET['port']) || $_GET['port'] < 1 || $_GET['port'] > 65535) {die(track('Invalid client port'));}
if (!$compact) {die(track("Your client doesn't support compact, please update your client"));}
//if (preg_match("/^Mozilla|^Opera|^Links|^Lynx/i", $user_agent)) { die("No");}
if (strlen($passkey) != 32) {die(track("Invalid passkey (" . strlen($passkey) . " - $passkey)"));}

// Get db connection
$dbh = new Database() or die(track('Database connection failed'));

// Client Ban
$stmt = $dbh->prepare("SELECT agent_name FROM agents");
$agentarray = $stmt->fetchAll(PDO::FETCH_COLUMN);
$useragent = substr($peerid, 0, 8);
foreach ($agentarray as $bannedclient) {
   if (@strpos($useragent, $bannedclient) !== false) {
       die(track('Client is banned'));
   }
}

// Get User (select user/group vars here)
$sql = "SELECT u.id, u.class, u.uploaded, u.downloaded, u.ip, u.passkey, g.can_download
   FROM users u
   INNER JOIN groups g
   ON u.class = g.group_id
   WHERE u.passkey=? AND u.enabled = ? AND u.status = ? LIMIT 1";
$stmt = $dbh->prepare($sql);
$stmt->execute([$passkey, 'yes', 'confirmed']);
$user = $stmt->fetch(PDO::FETCH_ASSOC);

// Get Torrent (select torrent vars here)  note = torrent['numpeers']
$sql = "SELECT id, info_hash, banned, freeleech, seeders + leechers
       AS numpeers, UNIX_TIMESTAMP(added)
   AS ts, seeders, leechers, times_completed
   FROM torrents WHERE info_hash=?";
$stmt = $dbh->prepare($sql);
$stmt->execute([$info_hash]);
$torrent = $stmt->fetch(PDO::FETCH_ASSOC);

// Do some more checks
if (!$user) {die(track("Cannot locate a user with that passkey!"));}
if ($user["can_download"] == "no") {die(track("You do not have permission to download."));}
if (!$torrent) {die(track("Torrent not found on this tracker - hash = " . $info_hash));}
if ($torrent["banned"] == 'yes') {die(track("Torrent has been banned - hash = " . $info_hash));}
$sql = $dbh->run("SELECT COUNT(*)
                 FROM peers
                 WHERE torrent=? AND passkey=?", [$torrent['id'], $passkey]);
$valid = $sql->rowCount();
if ($valid >= 1 && $seeder == 'no') {
   //die(track("Connection limit exceeded! You may only leech from one location at a time."));
}
$connect = isConnectable($ipadress, $port);
if ($connect) {
   $connectable = 'yes';
}else{
   $connectable = 'no';
}

// Prepare Peer Array
$peer_params = [
   'torrentid' => $torrent['id'],
   'peerid' => $peerid,
   'ipadress' => $ipadress,
   'port' => $port,
   'uploaded' => $uploaded,
   'downloaded' => $downloaded,
   'left' => $left,
   'seeder' => $seeder,
   'started' => TimeDate::get_date_time(),
   'lastaction' => TimeDate::get_date_time(),
   'connectable' => $connectable,
   'useragent' => $user_agent,
   'userid' => $user['id'],
   'passkey' => $passkey];

// Now Insert Peer Array or Update on Duplicate
$insert_peer = $dbh->prepare('INSERT INTO `peers` (`torrent`, `peer_id`, `ip`, `port`, `uploaded`, `downloaded`, `to_go`, `seeder`, `started`, `last_action`, `connectable`, `client`, `userid`, `passkey`) '
   . "VALUES (:torrentid, :peerid, :ipadress, :port, :uploaded, :downloaded, :left, :seeder, :started, :lastaction, :connectable, :useragent, :userid, :passkey) "
   . 'ON DUPLICATE KEY UPDATE `peer_id`=VALUES(`peer_id`), `ip` = VALUES(`ipadress`), `passkey`=VALUES(`passkey`), `port` = VALUES(`port`), `uploaded` = VALUES(`uploaded`), `downloaded` = VALUES(`downloaded`), `to_go` = VALUES(`to_go`), `seeder` = VALUES(`seeder`), `last_action` = VALUES(`last_action`), `connectable` = VALUES(`connectable`), `client` = VALUES(`client`), `userid` = VALUES(`userid`), `passkey` = VALUES(`passkey`),`id` = LAST_INSERT_ID(`peers`.`id`)');
$insert_peer->execute($peer_params);
$pk_peer = $dbh->lastInsertId();

// Select ip, port, peer_id to send back to client
$sql = "SELECT seeder, UNIX_TIMESTAMP(last_action) AS ez, peer_id, INET_NTOA(ip), port, uploaded, downloaded, userid, passkey FROM peers WHERE torrent=? AND passkey=? LIMIT $numwant";
$select_peer_torrent = $dbh->prepare($sql);
$select_peer_torrent->execute([$torrent['id'], $passkey]);
$reply = array(); //To be encoded and sent to the client
while ($r = $select_peer_torrent->fetch(PDO::FETCH_ASSOC)) { //Runs for every client with the same infohash
   $reply[] = array($r['ip'], $r['port'], $r['peer_id']);
   /*
   if ($r['peer_id'] === $peerid) {
       $currentpeer = $r; // the current connection = already in table(self)
   }
   */
}

// The Events
if ($event == 'started') { // when a connection is made or restarted after turn off
   if (($seeder == 'no' && $torrent['freeleech'] == 0)) {
       $dbh->run("INSERT INTO `snatched` (`uid`, `tid`, `stime`, `utime`) VALUES (?,?,?,?) ON DUPLICATE KEY UPDATE `utime` = ?", [$user['id'], $torrent['id'], gmtime(), gmtime(), gmtime()]);
   }
} elseif ($event == 'completed') { // when a download finishes in client
   // old updateset for completed
   $dbh->run("UPDATE torrents SET times_completed = $torrent[times_completed] + 1 WHERE id=$torrent[id]") or die(track("Tracker error: Unable to update torrent"));
   $dbh->run("INSERT INTO completed (userid, torrentid, date) VALUES (?,?,?)", [$user['id'], $torrent['id'], get_date_time()]);
   $dbh->run("UPDATE LOW_PRIORITY `snatched` SET `completed` = '1' WHERE `tid` = '$torrent[id]' AND `uid` = '$user[id]' AND `utime` = '" . gmtime() . "'");
} elseif ($event == 'stopped') { // when client is stopped correctly
   $dbh->run("DELETE FROM peers WHERE torrent = ? AND userid = ?", [$torrent['id'], $user['id']]);
}

// update user
$elapsed = ($seeder == 'yes') ? ANNOUNCEINTERVAL - floor(($self['ez'] - time()) / 60) : 0; //
if ($torrent["freeleech"] == 1) {
   $dbh->run("UPDATE users SET uploaded =? WHERE id=?", [$user['uploaded'] + $downloaded, $user['id']]) or die(track("Tracker error: Unable to update stats"));
} else {
   $dbh->run("UPDATE users SET uploaded =?, downloaded =? WHERE id=?", [$user['uploaded '] + $uploaded, $user['downloaded'] + $downloaded, $user['id']]) or die(track("Tracker error: Unable to update stats"));
   // snatch
   $dbh->run("UPDATE LOW_PRIORITY `snatched` SET `uload` = `uload` + '$uploaded', `dload` = `dload` + '$downloaded', `utime` = '" . gmtime() . "', `ltime` = `ltime` + '$elapsed' WHERE `tid` = '$torrent[id]' AND `uid` = '$user[id]'");
}


// Count the peers from to_go for seeders/leechers
$select_peers = $dbh->prepare('SELECT IFNULL(SUM(peers.to_go > 0), 0) AS leech, IFNULL(SUM(peers.to_go = 0), 0) AS seed '
   . 'FROM peers '
   . "WHERE peers.torrent = ? "
   . 'AND peers.last_action >= DATE_SUB(UTC_TIMESTAMP(), INTERVAL ' . (__INTERVAL + __INTERVAL) . ' SECOND) '
   . 'GROUP BY `peers`.`torrent`');
$select_peers->execute([$torrent['id']]);
$seeders = 0;
$leechers = 0;
if ($r = $select_peers->fetch(PDO::FETCH_NUM)) {
   $seeders = $r[1];
   $leechers = $r[0];
}

// Update Torrent -
if ($seeder == "yes") {
   if ($torrent["banned"] != "yes") { // DONT MAKE BANNED ONES VISIBLE {
       $dbh->run("UPDATE torrents SET seeders = ?, leechers = ?, last_action = ?, visible = ? WHERE id=?", [$seeders, $leechers, get_date_time(), 'yes', $torrent['id']]) or die(track("Tracker error: Unable to update torrent"));
   }
   $dbh->run("UPDATE torrents SET seeders = ?, leechers = ?, last_action = ? WHERE id=?", [$seeders, $leechers, get_date_time(), $torrent['id']]) or die(track("Tracker error: Unable to update torrent"));
}
/*
if (count($updateset)) {
   $dbh->run("UPDATE torrents SET " . join(",", $updateset) . " WHERE id=$torrent[id]") or die(track("Tracker error: Unable to update torrent"));
}
*/
Logs::write("$user[id] = user $event = event $downloaded = downloaded  $uploaded = uploaded $left = left $seeder = seeder $passkey = passkey $info_hash = info_hash $peerid = peer_id $port = port $user_agent = user agent $no_peer_id = no_peer_id $compact = cpmpact $numwant = numwant");
// Print out response
die(track($reply, $seeders[0], $leechers[0]));
Torrent Test — 2021-01-23 04:11:43 in M-BiTsy Support
here is the controller method mate just sends pm to owner/completed to reseed

   public function reseed()
   {
       if ($_SESSION["view_torrents"] == "no") {
           Session::flash('info', Lang::T("NO_TORRENT_VIEW"), URLROOT."/home");
       }
       $id = (int) $_GET["id"];
       if (isset($_COOKIE["reseed$id"])) {
           Session::flash('info', Lang::T("RESEED_ALREADY_ASK"), URLROOT."/home");
       }
       $res = DB::run("SELECT `owner`, `banned`, `external` FROM `torrents` WHERE `id` = $id");
       $row = $res->fetch(PDO::FETCH_ASSOC);
       if (!$row || $row["banned"] == "yes" || $row["external"] == "yes") {
           Session::flash('info', Lang::T("TORRENT_NOT_FOUND"), URLROOT."/home");
       }
       $res2 = DB::run("SELECT users.id FROM completed LEFT JOIN users ON completed.userid = users.id WHERE users.enabled = 'yes' AND users.status = 'confirmed' AND completed.torrentid = $id");
       $message = sprintf(Lang::T('RESEED_MESSAGE'), $_SESSION['username'], URLROOT, $id);
       while ($row2 = $res2->fetch(PDO::FETCH_ASSOC)) {
           DB::run("INSERT INTO `messages` (`subject`, `sender`, `receiver`, `added`, `msg`) VALUES ('" . Lang::T("RESEED_MES_SUBJECT") . "', '" . $_SESSION['id'] . "', '" . $row2['id'] . "', '" . TimeDate::get_date_time() . "', " . $message . ")");
       }
       if ($row["owner"] && $row["owner"] != $_SESSION["id"]) {
           DB::run("INSERT INTO `messages` (`subject`, `sender`, `receiver`, `added`, `msg`) VALUES ('Torrent Reseed Request', '" . $_SESSION['id'] . "', '" . $row['owner'] . "', '" . TimeDate::get_date_time() . "', " . $message . ")");
       }
       setcookie("reseed$id", $id, time() + 86400, '/');
       Session::flash('info', Lang::T("RESEED_SENT"), URLROOT."/home");
   }


Message received
STorrents2020 has requested a re-seed on the torrent below because there are currently no or few seeds:

https://torrenttrader.uk/torrents/read?id=1
Thank You!
Torrent Test — 2021-01-22 20:26:41 in M-BiTsy Support
Hoping to update github at the end of this month, just need to skip through admincp a bit more first

So ive added a torrent (just a old movie) so members can see the torrent page i have added a copy of the normal home page as well for viewing before i open site at https://torrenttrader.uk/example

On the torrent i added imdb (for show), i have rewritten the announce.php from scratch which is a pain in the arse so members are welcome to download the torrent to help test

If you download would you please post here which client you used or any issues, if it does not start immediately please give it a few minutes

https://torrenttrader.uk/torrents/read?id=1

ps = if you right click  on screen you can inspect and see mobile view
this is the bbcode parser (well function) this is been looked at, the old forum used magic quotes and so linebreakers have been inputted to the old post thats caused a bit of a headache adding something better.
@storrents did you get any further with your parser
Captcha TTv3 — 2021-01-17 18:37:35 in v3 Mods in Progress
little class i made using this https://torrenttrader.uk/topic?topicid=9935#post67759

first in config the keys you get from here https://www.google.com/recaptcha/about/


// Captcha use google api
$site_config['CAPTCHA_ON'] =true;
$site_config['CAPTCHA_KEY'] = 'googlecaptchakey';
$site_config['CAPTCHA_SECRET'] = 'googlecaptchasecret';


in account login find
if ($_POST["username"] && $_POST["password"]) {


add below
(new Captcha)->response($_POST['g-recaptcha-response']);


find
<tr><td align="center"><b><?php echo T_("PASSWORD"); ?>:</b> <input type="password" size="40" name="password" /></td></tr>


below add
<?php  (new Captcha)->html(); ?>


find in backend / function.php
require_once(BACKEND."/languages.php");


add under
require_once(BACKEND."/Captcha.php");


make file called Captcha.php add in backend folder
<?php

class Captcha
{
  private $key;
  private $secret;

  public function __construct()
  {
      global $site_config;
  $this->key = $site_config['CAPTCHA_KEY'];
      $this->secret = $site_config['CAPTCHA_SECRET'];
  }

  public function response($captcha)
  {
      global $site_config;
  if ($site_config['CAPTCHA_ON']) {
          if (!$captcha) {
              autolink(T_('<b>Please check the the captcha form.</b>'), "account-login.php");
          }
          $secret = $site_config['CAPTCHA_SECRET'];
          $verifyResponse = file_get_contents('https://www.google.com/recaptcha/api/siteverify?secret=' . $this->secret . '&response=' . $captcha);
          $responseData = json_decode($verifyResponse);
          if ($responseData->success) {
              // its successfull so let it go
      } else {
              autolink(T_('<b>Please check the the captcha form.</b>'), "account-login.php");
  }
       }
  }

  public function html()
  {
      global $site_config;
  if ($site_config['CAPTCHA_ON']) {
          return print("<div class='g-recaptcha' data-theme='light' data-sitekey='" . $this->key . "'></div>");
      }
  }

}
so far managed to fix everything  that pops up  :-)   do the smilies in shoutbox and forum reply work correctly on your browser?  might give the torrent side a qiuck test later today

bugs fixed on master
2021-01-18:
  • The mobile login page is not centering.  [img]https://photos.app.goo.gl/UW3z3oFnejgw7yVK7[/img]
  • When you forget to tick the Google thingy, you get the message "oops something went wrong". This should be more predictive as to what you need to correct.
  • mode vip original — 2021-01-14 21:09:15 in v3 Support
    if it does not work try a wrap with class


    like so

    }else{
       $upthis = max(0, $uploaded - $self["uploaded"]);
       $downthis = max(0, $downloaded - $self["downloaded"]);
       if (($upthis > 0 || $downthis > 0) && is_valid_id($userid)){ // LIVE STATS!)
    if ($torrent["freeleech"] == 1){
    if ($user["class"] != 4) {
    SQL_Query_exec("UPDATE users SET uploaded = uploaded + $upthis WHERE id=$userid") or err("Tracker error: Unable to update stats");
    }
    }else{
    if ($user["class"] != 4) {
    SQL_Query_exec("UPDATE users SET uploaded = uploaded + $upthis, downloaded = downloaded + $downthis WHERE id=$userid") or err("Tracker error: Unable to update stats");
    }
    }
       }
    }//END WAIT AND STATS UPDATE
    mode vip original — 2021-01-14 20:55:13 in v3 Support
    i think this can be done in announce.php

    announce updates user upload/download from tracker so to stop vip

    in this example i use number 4 for vip group
    find in announce

    }else{
       $upthis = max(0, $uploaded - $self["uploaded"]);
       $downthis = max(0, $downloaded - $self["downloaded"]);

       if (($upthis > 0 || $downthis > 0) && is_valid_id($userid)){ // LIVE STATS!)
    if ($torrent["freeleech"] == 1){
    SQL_Query_exec("UPDATE users SET uploaded = uploaded + $upthis WHERE id=$userid") or err("Tracker error: Unable to update stats");
    }else{
    SQL_Query_exec("UPDATE users SET uploaded = uploaded + $upthis, downloaded = downloaded + $downthis WHERE id=$userid") or err("Tracker error: Unable to update stats");
    }
       }
    }//END WAIT AND STATS UPDATE


    add class to sql

    }else{
       $upthis = max(0, $uploaded - $self["uploaded"]);
       $downthis = max(0, $downloaded - $self["downloaded"]);

       if (($upthis > 0 || $downthis > 0) && is_valid_id($userid)){ // LIVE STATS!)
    if ($torrent["freeleech"] == 1){
    SQL_Query_exec("UPDATE users SET uploaded = uploaded + $upthis WHERE id=$userid AND class !=4") or err("Tracker error: Unable to update stats");
    }else{
    SQL_Query_exec("UPDATE users SET uploaded = uploaded + $upthis, downloaded = downloaded + $downthis WHERE id=$userid AND class !=4") or err("Tracker error: Unable to update stats");
    }
       }
    }//END WAIT AND STATS UPDATE


    i have not tested this
    To transfer data (sql) should be very easy just need to go to your host control panel
    Go to database section where myphpadmin is and at the top there should be a option to export
    You can click custom and only download structure, no data then a simple update list can be done  (y) if you send me a copy of the exported structure I'll take a quick look

    The only issue updating tbdev or any other tracker including old TT is that the passwords are old using md5 this can be fixed pretty easy with a small snippet of code
    added exceptions back to database now we have basic exceptions in database
    so members can see where error is to ask for assistance or investigate, then in config we can turn debug on, used to log all detailed exceptions to the log files
    we can also turn display errors on, turn them off or show / log to file depending on live site or test
    upload page on mobile, not sure why you would upload on a mobile device lol, and the torrent edit page
    all bootstrap is done now final release  next month  ?
    Users online

    No users online

    Search



    Statistics

      Torrents

    • Tracking: 3
    • Todays torrents: 0
    • Seeders: 0
    • Leechers: 0
    • Peers: 0
    • Downloaded: 89.96 GB
    • Uploaded: 9.86 GB

    • Members

    • We have: 838
    • New today: 0
    • Guest today: 9

    • Online

    • Total online: 2
    • Members: 0
    • Guests online: 2
    • Comments: 3
    • Messages: 1,728