Hello guys,
is reinstalling my old TT 2.5 and has a couple of minor issues with scripting.
1. Shoutbox new torrent that has worked on an old server is now starting to fu** and does not want to work
2. When uploading a new torrent, an SQL error message will appear
Source code for torrent-upload.php
Thanks for a help from all of you guys
www.exyusubs.com
TorrentTrader V3.8.3 (SE)
OS: AlmaLinux 9.9 (BC)
Apache version: 2.4.71
PHP version: 8.5.13 (PHP-FPM)
MySQL version: 10.11.18-MariaDB
is reinstalling my old TT 2.5 and has a couple of minor issues with scripting.
1. Shoutbox new torrent that has worked on an old server is now starting to fu** and does not want to work
2. When uploading a new torrent, an SQL error message will appear
Database Error in torrents-upload.php on line 274: Out of range value for column 'leechers' at row 1. Query was: UPDATE torrents SET leechers='-1', seeders='-1',times_completed='-1',last_action= '2021-02-11 18:57:56',visible='yes' WHERE id='718'.Source code for torrent-upload.php
//EXTERNAL SCRAPE
if ($external=='yes' && $site_config['UPLOADSCRAPE']){
$tracker=str_replace("/announce","/scrape",$announce);
$stats = torrent_scrape_url($tracker, $infohash);
$seeders = (int) strip_tags($stats['seeds']);
$leechers = (int) strip_tags($stats['peers']);
$downloaded = (int) strip_tags($stats['downloaded']);
SQL_Query_exec("UPDATE torrents SET leechers='".$leechers."', seeders='".$seeders."',times_completed='".$downloaded."',last_action= '".get_date_time()."',visible='yes' WHERE id='".$id."'");
}
//END SCRAPE
// Message shoutbox news torrent by thib
$image = $inames[0];
$membre = ( $anon == 'yes' || $CURUSER['privacy'] == 'strong' ) ? 'Anonyme' : $CURUSER['username'];
$insert = "Torrent [url=".$site_config['SITEURL']."/torrents-details.php?id=".$id."]".$torrent."[/url] upravo je postavljen od: ".($anon == 'no' ? " [url=".$site_config['SITEURL']."/account-details.php?id=".$CURUSER['id']."] ".$CURUSER["username"]."[/url]" : "")."";
SQL_Query_exec("INSERT INTO `shoutbox` (`msgid`, `user`, `message`, `date`, `userid`) VALUES(null, 'TorrOp', '$insert', '".get_date_time()."', '1')");
// EndThanks for a help from all of you guys
www.exyusubs.com
TorrentTrader V3.8.3 (SE)
OS: AlmaLinux 9.9 (BC)
Apache version: 2.4.71
PHP version: 8.5.13 (PHP-FPM)
MySQL version: 10.11.18-MariaDB