diff --git a/api.php b/api.php index 908b4b9..74c7eef 100644 --- a/api.php +++ b/api.php @@ -32,8 +32,8 @@ $results = array("error" => "disabled"); else { - require "engines/bittorrent/thepiratebay.php"; - $results = get_thepiratebay_results($query_encoded); + require "engines/bittorrent/merge.php"; + $results = get_merged_torrent_results($query_encoded); } break; default: diff --git a/config.php b/config.php index 2023258..691094a 100755 --- a/config.php +++ b/config.php @@ -11,6 +11,8 @@ // Disable BitTorrent search $config_disable_bittorent_search = false; + $config_bittorent_trackers = "&tr=http%3A%2F%2Fnyaa.tracker.wf%3A7777%2Fannounce&tr=udp%3A%2F%2Fopen.stealth.si%3A80%2Fannounce&tr=udp%3A%2F%2Ftracker.opentrackr.org%3A1337%2Fannounce&tr=udp%3A%2F%2Fexodus.desync.com%3A6969%2Fannounce&tr=udp%3A%2F%2Ftracker.torrent.eu.org%3A451%2Fannounce"; + /* youtube.com results will be replaced with the given invidious instance Get online invidious instances from here: https://docs.invidious.io/Invidious-Instances.md diff --git a/engines/bittorrent/merge.php b/engines/bittorrent/merge.php new file mode 100644 index 0000000..16f4007 --- /dev/null +++ b/engines/bittorrent/merge.php @@ -0,0 +1,46 @@ +"; + + foreach($results as $result) + { + $source = $result["source"]; + $name = $result["name"]; + $magnet = $result["magnet"]; + $seeders = $result["seeders"]; + $leechers = $result["leechers"]; + $size = $result["size"]; + + echo "