Quote:
Originally Posted by BlackWolf
|
Attention
download.php
Code:
$dict['comment']="$DEFAULTBASEURL/details_$id"; //torrent comment
$dict['announce-list'][][0] = $announce_urls[0]."?passkey=$CURUSER[passkey]"; // Just add one tracker for multitrackers, we are the last
}else
$dict['announce'] = $announce_urls[0]."?passkey=$CURUSER[passkey]";//"$DEFAULTBASEURL/announce.php?passkey=$CURUSER[passkey]";
$dict['comment']="$DEFAULTBASEURL/details_$id"; //torrent comment
$dict['value']['source']="$DEFAULTBASEURL/details_$id"; //torrent comment
Attention
init.php
Code:
// DEFINE IMPORTANT CONSTANTS
define ('TIMENOW', time());
$url = explode('/', htmlspecialchars_uni($_SERVER['PHP_SELF']));
array_pop($url);
$DEFAULTBASEURL = (($_SERVER['SERVER_PORT'] == 443) ? "https://" : "http://").htmlspecialchars_uni($_SERVER['HTTP_HOST']).implode('/', $url);
$BASEURL = $DEFAULTBASEURL;
$announce_urls = array();
$announce_urls[] = "$DEFAULTBASEURL/announce.php";
Attention
takeedit.php
Code:
if(!$_POST["multitracker"]){
$dict['announce'] = $announce_urls[0]; // change announce url to local
$dict['info']['private'] = 1; // add private tracker flag
$dict['info']['source'] = "[$DEFAULTBASEURL] $SITENAME"; // add link for bitcomet users
unset($dict['announce-list']); // remove multi-tracker capability
unset($dict['nodes']); // remove cached peers (Bitcomet & Azareus)
unset($dict['info']['crc32']); // remove crc32
unset($dict['info']['ed2k']); // remove ed2k
unset($dict['info']['md5sum']); // remove md5sum
unset($dict['info']['sha1']); // remove sha1
unset($dict['info']['tiger']); // remove tiger
unset($dict['azureus_properties']); // remove azureus properties
}else{
if(!empty($dict['announce-list'])){$parsed_urls = array();
foreach ($dict['announce-list'] as $al_url) {
$al_url[0] = trim($al_url[0]); // Trim url for match below and prevent "Invalid tracker url." error message if URL contains " " before proto://
if ($al_url[0] == 'https://retracker.local/announce') continue;
if (!preg_match('#^(udp|https)://#si', $al_url[0])) continue; // Skip not https:// or udp:// urls
if (in_array($al_url[0], $parsed_urls)) continue; // To skip doubled announce urls
$url_array = parse_url($al_url[0]);
if (substr($url_array['host'], -6) == '.local') continue; // Skip any .local domains
$parsed_urls[] = $al_url[0];
// What if in torrent there are two identical announcers? because REPLACE INTO
mysql_query('REPLACE INTO torrents_scrape (tid, info_hash, url) VALUES ('.implode(', ', array_map('sqlesc', array($next_id, $infohash, $al_url[0]))).')') or sqlerr(__FILE__,__LINE__);
}}}
/////////
$dict = BDecode(BEncode($dict)); // double up on the becoding solves the occassional misgenerated infohash
$dict['value']['comment']=bdec(benc_str("$DEFAULTBASEURL/details_$id")); //torrent comment
$dict['created by'] = "$CURUSER[username]"; // change created by
$dict['publisher'] = "$CURUSER[username]"; // change publisher
$dict['publisher.utf-8'] = "$CURUSER[username]"; // change publisher.utf-8
$dict['publisher-url'] = "$DEFAULTBASEURL/users_$CURUSER[id]"; // change publisher-url
$dict['publisher-url.utf-8'] = "$DEFAULTBASEURL/users_$CURUSER[id]"; // change publisher-url.utf-8
Attention
takeupload.php
Code:
if ($multi_torrent == 'no') {
$dict['value']['announce'] = $announce_urls[0]; // change announce url to local
$dict['info']['private'] = 1; // add private tracker flag
$dict['info']['source'] = "[$DEFAULTBASEURL] $SITENAME"; // add link for bitcomet users
Attention
in utorrent select all torrents of the site and click - change. After you change to the new site address and restart the torrents - Update the tracker, That's it !!!