diff --git a/src/Jackett.Common/Definitions/1337x.yml b/src/Jackett.Common/Definitions/1337x.yml index 594f30a2c..683ac5ebe 100644 --- a/src/Jackett.Common/Definitions/1337x.yml +++ b/src/Jackett.Common/Definitions/1337x.yml @@ -140,6 +140,7 @@ download: # the .torrent url is on the on the details page selector: ul li a[href^="{{ .Config.downloadlink }}"] + attribute: href search: paths: diff --git a/src/Jackett.Common/Definitions/acgsou.yml b/src/Jackett.Common/Definitions/acgsou.yml index a3944d6c8..166bcea28 100644 --- a/src/Jackett.Common/Definitions/acgsou.yml +++ b/src/Jackett.Common/Definitions/acgsou.yml @@ -38,6 +38,7 @@ download: selector: a[href^="magnet:?xt="] + attribute: href search: paths: diff --git a/src/Jackett.Common/Definitions/arabafenice.yml b/src/Jackett.Common/Definitions/arabafenice.yml index 7ca0bc998..f48971862 100644 --- a/src/Jackett.Common/Definitions/arabafenice.yml +++ b/src/Jackett.Common/Definitions/arabafenice.yml @@ -125,6 +125,7 @@ thanks: 1 rndval: "1487013827343" selector: a[href^="download.php?id="] + attribute: href search: paths: diff --git a/src/Jackett.Common/Definitions/arenabg.yml b/src/Jackett.Common/Definitions/arenabg.yml index 1b8517cd7..37329f551 100644 --- a/src/Jackett.Common/Definitions/arenabg.yml +++ b/src/Jackett.Common/Definitions/arenabg.yml @@ -102,6 +102,7 @@ download: selector: a[href*="{{ .Config.downloadlink }}"] + attribute: href search: paths: diff --git a/src/Jackett.Common/Definitions/asiancinema.yml b/src/Jackett.Common/Definitions/asiancinema.yml index b746f18cc..8d7d87b1d 100644 --- a/src/Jackett.Common/Definitions/asiancinema.yml +++ b/src/Jackett.Common/Definitions/asiancinema.yml @@ -67,6 +67,7 @@ download: selector: a[href*="/download/"] + attribute: href search: paths: diff --git a/src/Jackett.Common/Definitions/bigtorrent.yml b/src/Jackett.Common/Definitions/bigtorrent.yml index eaff39ec9..0547420da 100644 --- a/src/Jackett.Common/Definitions/bigtorrent.yml +++ b/src/Jackett.Common/Definitions/bigtorrent.yml @@ -55,7 +55,8 @@ download: selector: a[href^="download.php?id="] - + attribute: href + search: paths: - path: browse.php diff --git a/src/Jackett.Common/Definitions/bittorrentam.yml b/src/Jackett.Common/Definitions/bittorrentam.yml index 51b93cb05..e0fd4b3e6 100644 --- a/src/Jackett.Common/Definitions/bittorrentam.yml +++ b/src/Jackett.Common/Definitions/bittorrentam.yml @@ -41,6 +41,7 @@ download: selector: a[ href^="magnet:?xt="] + attribute: href search: paths: diff --git a/src/Jackett.Common/Definitions/btsow.yml b/src/Jackett.Common/Definitions/btsow.yml index a850136c5..deed67c80 100644 --- a/src/Jackett.Common/Definitions/btsow.yml +++ b/src/Jackett.Common/Definitions/btsow.yml @@ -21,6 +21,8 @@ download: selector: a#magnetOpen + attribute: href + search: paths: - path: "search/{{if .Keywords}}{{ .Keywords}}{{else}}2019{{end}}" diff --git a/src/Jackett.Common/Definitions/classix.yml b/src/Jackett.Common/Definitions/classix.yml index 9536d8189..029deb330 100644 --- a/src/Jackett.Common/Definitions/classix.yml +++ b/src/Jackett.Common/Definitions/classix.yml @@ -28,7 +28,8 @@ download: selector: a[href^="download.php?id="] - + attribute: href + search: paths: - path: torrents-search.php diff --git a/src/Jackett.Common/Definitions/crazyscorner.yml b/src/Jackett.Common/Definitions/crazyscorner.yml index 45dce2a7c..520509179 100644 --- a/src/Jackett.Common/Definitions/crazyscorner.yml +++ b/src/Jackett.Common/Definitions/crazyscorner.yml @@ -92,6 +92,7 @@ infohash: "\"{{ .DownloadUri.Query.id }}\"" thanks: 1 selector: a[href^="download.php?id="] + attribute: href search: paths: diff --git a/src/Jackett.Common/Definitions/crazyspirits.yml b/src/Jackett.Common/Definitions/crazyspirits.yml index 1ad416f2f..19477694c 100644 --- a/src/Jackett.Common/Definitions/crazyspirits.yml +++ b/src/Jackett.Common/Definitions/crazyspirits.yml @@ -142,6 +142,7 @@ to: "give" torrent: "{{ .DownloadUri.Query.id }}" selector: a:contains("Télécharger ce torrent") + attribute: href search: paths: diff --git a/src/Jackett.Common/Definitions/demonoid.yml b/src/Jackett.Common/Definitions/demonoid.yml index 50499bbe6..6ac438af3 100644 --- a/src/Jackett.Common/Definitions/demonoid.yml +++ b/src/Jackett.Common/Definitions/demonoid.yml @@ -284,6 +284,7 @@ download: selector: a[href^="magnet:?xt="] + attribute: href search: paths: diff --git a/src/Jackett.Common/Definitions/downloadville.yml b/src/Jackett.Common/Definitions/downloadville.yml index 13456f9d2..d4df0c3ab 100644 --- a/src/Jackett.Common/Definitions/downloadville.yml +++ b/src/Jackett.Common/Definitions/downloadville.yml @@ -185,6 +185,7 @@ thanks: 1 rndval: "1487013827343" selector: a[href^="download.php?id="] + attribute: href search: paths: diff --git a/src/Jackett.Common/Definitions/dxp.yml b/src/Jackett.Common/Definitions/dxp.yml index 0ae7cefa2..d877c3986 100644 --- a/src/Jackett.Common/Definitions/dxp.yml +++ b/src/Jackett.Common/Definitions/dxp.yml @@ -80,6 +80,7 @@ download: selector: a[href^="download.php?id="] + attribute: href search: # https://dxp.ru/torrents.php?search=&sort=4&type=desc diff --git a/src/Jackett.Common/Definitions/ebooks-shares.yml b/src/Jackett.Common/Definitions/ebooks-shares.yml index 8818bdbe9..8602169a6 100644 --- a/src/Jackett.Common/Definitions/ebooks-shares.yml +++ b/src/Jackett.Common/Definitions/ebooks-shares.yml @@ -297,6 +297,7 @@ download: selector: a[href^="download.php?id="] + attribute: href search: paths: diff --git a/src/Jackett.Common/Definitions/estrenosdtl.yml b/src/Jackett.Common/Definitions/estrenosdtl.yml index b5eaf68c4..a02aa5b9f 100644 --- a/src/Jackett.Common/Definitions/estrenosdtl.yml +++ b/src/Jackett.Common/Definitions/estrenosdtl.yml @@ -42,6 +42,7 @@ download: selector: a.linktorrent + attribute: href search: paths: diff --git a/src/Jackett.Common/Definitions/ettv.yml b/src/Jackett.Common/Definitions/ettv.yml index ee80f2e27..a7153c577 100644 --- a/src/Jackett.Common/Definitions/ettv.yml +++ b/src/Jackett.Common/Definitions/ettv.yml @@ -96,6 +96,7 @@ download: selector: a[href^="{{ .Config.downloadlink }}"] + attribute: href search: path: "{{ if .Keywords }}torrents-search.php{{else}}torrents.php{{end}}" diff --git a/src/Jackett.Common/Definitions/extremetorrents.yml b/src/Jackett.Common/Definitions/extremetorrents.yml index d088dfaff..34ab2a505 100644 --- a/src/Jackett.Common/Definitions/extremetorrents.yml +++ b/src/Jackett.Common/Definitions/extremetorrents.yml @@ -76,6 +76,7 @@ text: "{{ .Config.thankyou }}" submit: Opslaan selector: a[href^="download.php?id="] + attribute: href search: paths: diff --git a/src/Jackett.Common/Definitions/exttorrents.yml b/src/Jackett.Common/Definitions/exttorrents.yml index b15315840..1f589f995 100644 --- a/src/Jackett.Common/Definitions/exttorrents.yml +++ b/src/Jackett.Common/Definitions/exttorrents.yml @@ -44,6 +44,7 @@ download: selector: a[href^="magnet:?xt="] + attribute: href search: paths: diff --git a/src/Jackett.Common/Definitions/finvip.yml b/src/Jackett.Common/Definitions/finvip.yml index 828357977..9d09b6dd4 100644 --- a/src/Jackett.Common/Definitions/finvip.yml +++ b/src/Jackett.Common/Definitions/finvip.yml @@ -91,6 +91,7 @@ download: selector: a[href^="download.php?id="] + attribute: href search: paths: diff --git a/src/Jackett.Common/Definitions/firebit.yml b/src/Jackett.Common/Definitions/firebit.yml index c3682bc06..d99b14aab 100644 --- a/src/Jackett.Common/Definitions/firebit.yml +++ b/src/Jackett.Common/Definitions/firebit.yml @@ -32,6 +32,7 @@ download: selector: a[href^="/download.php?id="] + attribute: href search: # http://firebit.net/index.php?do=search&type=simple&q=2019 diff --git a/src/Jackett.Common/Definitions/galeriens.yml b/src/Jackett.Common/Definitions/galeriens.yml index 319ed109c..5c3863499 100644 --- a/src/Jackett.Common/Definitions/galeriens.yml +++ b/src/Jackett.Common/Definitions/galeriens.yml @@ -233,6 +233,7 @@ download: selector: a[href*="/Telechargement/"] + attribute: href search: paths: diff --git a/src/Jackett.Common/Definitions/gamestorrents.yml b/src/Jackett.Common/Definitions/gamestorrents.yml index baa0d65ee..72cf74bce 100644 --- a/src/Jackett.Common/Definitions/gamestorrents.yml +++ b/src/Jackett.Common/Definitions/gamestorrents.yml @@ -30,6 +30,7 @@ download: selector: a#download_torrent + attribute: href search: paths: diff --git a/src/Jackett.Common/Definitions/generationfree.yml b/src/Jackett.Common/Definitions/generationfree.yml index 62d41e2f0..7168efd40 100644 --- a/src/Jackett.Common/Definitions/generationfree.yml +++ b/src/Jackett.Common/Definitions/generationfree.yml @@ -179,6 +179,7 @@ to: "give" torrent: "{{ .DownloadUri.Query.id }}" selector: a[href^="download.php?id="] + attribute: href search: paths: diff --git a/src/Jackett.Common/Definitions/girotorrent.yml b/src/Jackett.Common/Definitions/girotorrent.yml index 43dc655fe..8c74bf64f 100644 --- a/src/Jackett.Common/Definitions/girotorrent.yml +++ b/src/Jackett.Common/Definitions/girotorrent.yml @@ -123,6 +123,7 @@ thanks: "1" rndval: "1487013827343" selector: a[href^="download.php?id="] + attribute: href search: paths: diff --git a/src/Jackett.Common/Definitions/gktorrent.yml b/src/Jackett.Common/Definitions/gktorrent.yml index 49a60a7a9..de340a7ec 100644 --- a/src/Jackett.Common/Definitions/gktorrent.yml +++ b/src/Jackett.Common/Definitions/gktorrent.yml @@ -54,6 +54,7 @@ download: selector: a[href*="{{ .Config.downloadlink }}"] + attribute: href search: paths: diff --git a/src/Jackett.Common/Definitions/hdreactor.yml b/src/Jackett.Common/Definitions/hdreactor.yml index 0535915c2..1e3fc0c9c 100644 --- a/src/Jackett.Common/Definitions/hdreactor.yml +++ b/src/Jackett.Common/Definitions/hdreactor.yml @@ -50,6 +50,7 @@ download: selector: a[href^="magnet:?xt="] + attribute: href search: # https://hdreactor.net/index.php?do=search&subaction=search&showposts=1&story=2019&catlist[]=2001&catlist[]=2006 diff --git a/src/Jackett.Common/Definitions/isohunt2.yml b/src/Jackett.Common/Definitions/isohunt2.yml index 9f20f7f84..a8118f653 100644 --- a/src/Jackett.Common/Definitions/isohunt2.yml +++ b/src/Jackett.Common/Definitions/isohunt2.yml @@ -52,6 +52,7 @@ download: selector: a.btn-magnet + attribute: href filters: - name: querystring args: url diff --git a/src/Jackett.Common/Definitions/itorrent.yml b/src/Jackett.Common/Definitions/itorrent.yml index 68d1e358d..6c626ef5e 100644 --- a/src/Jackett.Common/Definitions/itorrent.yml +++ b/src/Jackett.Common/Definitions/itorrent.yml @@ -44,6 +44,7 @@ download: selector: a[href^="/torrentfiles/"] + attribute: href search: paths: diff --git a/src/Jackett.Common/Definitions/leporno.yml b/src/Jackett.Common/Definitions/leporno.yml index 485777398..af144391f 100644 --- a/src/Jackett.Common/Definitions/leporno.yml +++ b/src/Jackett.Common/Definitions/leporno.yml @@ -37,6 +37,7 @@ download: selector: a[href*="/dl.php?id="] + attribute: href search: paths: diff --git a/src/Jackett.Common/Definitions/limetorrents.yml b/src/Jackett.Common/Definitions/limetorrents.yml index c056bdc3b..26497374d 100644 --- a/src/Jackett.Common/Definitions/limetorrents.yml +++ b/src/Jackett.Common/Definitions/limetorrents.yml @@ -52,6 +52,7 @@ download: # the .torrent url is on the on the details page selector: a.csprite_dltorrent[href^="{{ .Config.downloadlink }}"] + attribute: href search: paths: diff --git a/src/Jackett.Common/Definitions/monova.yml b/src/Jackett.Common/Definitions/monova.yml index 43c5cadd4..a2d4fca8e 100644 --- a/src/Jackett.Common/Definitions/monova.yml +++ b/src/Jackett.Common/Definitions/monova.yml @@ -30,6 +30,7 @@ download: selector: a#download-file + attribute: href search: paths: diff --git a/src/Jackett.Common/Definitions/movcr.yml b/src/Jackett.Common/Definitions/movcr.yml index c8b60ab5b..5611ef90f 100644 --- a/src/Jackett.Common/Definitions/movcr.yml +++ b/src/Jackett.Common/Definitions/movcr.yml @@ -23,6 +23,7 @@ download: selector: a[href^="/torrents/"] + attribute: href search: paths: diff --git a/src/Jackett.Common/Definitions/moviesdvdr.yml b/src/Jackett.Common/Definitions/moviesdvdr.yml index 276cbdc7b..05bd7095d 100644 --- a/src/Jackett.Common/Definitions/moviesdvdr.yml +++ b/src/Jackett.Common/Definitions/moviesdvdr.yml @@ -20,6 +20,7 @@ download: selector: a.torrent_download + attribute: href search: paths: diff --git a/src/Jackett.Common/Definitions/nntt.yml b/src/Jackett.Common/Definitions/nntt.yml index ae8ead4b0..920b51694 100644 --- a/src/Jackett.Common/Definitions/nntt.yml +++ b/src/Jackett.Common/Definitions/nntt.yml @@ -660,6 +660,7 @@ download: selector: a[href^="./download/file.php?id="] + attribute: href search: # http://www.nntt.org/search.php?sr=topics&sf=titleonly&fp=1&tracker_search=torrent&keywords=2019&fid[]=154 diff --git a/src/Jackett.Common/Definitions/oxtorrent.yml b/src/Jackett.Common/Definitions/oxtorrent.yml index 8df3054ec..a2a37d26d 100644 --- a/src/Jackett.Common/Definitions/oxtorrent.yml +++ b/src/Jackett.Common/Definitions/oxtorrent.yml @@ -39,6 +39,7 @@ download: selector: a[href*="{{ .Config.downloadlink }}"] + attribute: href search: paths: diff --git a/src/Jackett.Common/Definitions/piratbit.yml b/src/Jackett.Common/Definitions/piratbit.yml index 21d7554ec..bfceb7f79 100644 --- a/src/Jackett.Common/Definitions/piratbit.yml +++ b/src/Jackett.Common/Definitions/piratbit.yml @@ -626,6 +626,7 @@ download: selector: a[href^="magnet:?xt="] + attribute: href search: paths: diff --git a/src/Jackett.Common/Definitions/prostylex.yml b/src/Jackett.Common/Definitions/prostylex.yml index 62051535f..28f2fcd93 100644 --- a/src/Jackett.Common/Definitions/prostylex.yml +++ b/src/Jackett.Common/Definitions/prostylex.yml @@ -91,6 +91,7 @@ download: selector: a[href^="magnet:?"] + attribute: href search: paths: diff --git a/src/Jackett.Common/Definitions/rus-media.yml b/src/Jackett.Common/Definitions/rus-media.yml index 4b04c194f..7f37ecfd3 100644 --- a/src/Jackett.Common/Definitions/rus-media.yml +++ b/src/Jackett.Common/Definitions/rus-media.yml @@ -295,6 +295,7 @@ download: selector: a[href^="./download/file.php?id="] + attribute: href search: # http://rus-media.org/search.php?tracker_search=torrent&sr=topics&keywords=2019&fid[]=54 diff --git a/src/Jackett.Common/Definitions/seedfile.yml b/src/Jackett.Common/Definitions/seedfile.yml index 597ee3d47..f483fcba6 100644 --- a/src/Jackett.Common/Definitions/seedfile.yml +++ b/src/Jackett.Common/Definitions/seedfile.yml @@ -50,9 +50,10 @@ - selector: div.recover-error2 test: path: profile.php - + download: selector: a[href^="download.php/"] + attribute: href search: paths: diff --git a/src/Jackett.Common/Definitions/seedpeer.yml b/src/Jackett.Common/Definitions/seedpeer.yml index eb50242cb..d4d114078 100644 --- a/src/Jackett.Common/Definitions/seedpeer.yml +++ b/src/Jackett.Common/Definitions/seedpeer.yml @@ -21,6 +21,7 @@ download: selector: a[href*="/torrent/"] + attribute: href search: # https://seedpeer.me/today diff --git a/src/Jackett.Common/Definitions/siambit.yml b/src/Jackett.Common/Definitions/siambit.yml index 7c7f8251d..4a46fd8ba 100644 --- a/src/Jackett.Common/Definitions/siambit.yml +++ b/src/Jackett.Common/Definitions/siambit.yml @@ -103,6 +103,7 @@ _action: "say_thank" id: "{{ .DownloadUri.Query.id }}" selector: a[href^="downloadnew.php?id="] + attribute: href search: paths: diff --git a/src/Jackett.Common/Definitions/soundpark.yml b/src/Jackett.Common/Definitions/soundpark.yml index 5078ff9bb..abb4cff84 100644 --- a/src/Jackett.Common/Definitions/soundpark.yml +++ b/src/Jackett.Common/Definitions/soundpark.yml @@ -35,6 +35,7 @@ download: selector: a[href^="/album/download-torrent/"] + attribute: href search: paths: diff --git a/src/Jackett.Common/Definitions/spacetorrent.yml b/src/Jackett.Common/Definitions/spacetorrent.yml index 2d74db905..77ad5fc8d 100644 --- a/src/Jackett.Common/Definitions/spacetorrent.yml +++ b/src/Jackett.Common/Definitions/spacetorrent.yml @@ -41,6 +41,7 @@ download: selector: a[href^="magnet:?xt="] + attribute: href search: path: recherche diff --git a/src/Jackett.Common/Definitions/sporthd.yml b/src/Jackett.Common/Definitions/sporthd.yml index 10007719d..a4441ce40 100644 --- a/src/Jackett.Common/Definitions/sporthd.yml +++ b/src/Jackett.Common/Definitions/sporthd.yml @@ -90,7 +90,7 @@ type: info label: How to get the Cookie default: "
  1. Login to this tracker in your browser
  2. Open the DevTools panel by pressing F12
  3. Select the Network tab
  4. Click on the Doc button
  5. Refresh the page by pressing F5
  6. Select the Headers tab
  7. Find 'cookie:' in the Request Headers section
  8. Copy & paste the whole cookie string to here
" - + login: method: cookie inputs: @@ -100,7 +100,8 @@ download: selector: a[href^="download.php?id="] - + attribute: href + search: paths: - path: browse.php diff --git a/src/Jackett.Common/Definitions/tazmaniaden.yml b/src/Jackett.Common/Definitions/tazmaniaden.yml index 5eb325816..06d971613 100644 --- a/src/Jackett.Common/Definitions/tazmaniaden.yml +++ b/src/Jackett.Common/Definitions/tazmaniaden.yml @@ -35,6 +35,7 @@ torrent: "{{ .DownloadUri.Query.id }}" submit: "Thanks!" selector: a[href^="download.php?id="] + attribute: href search: paths: diff --git a/src/Jackett.Common/Definitions/tfile.yml b/src/Jackett.Common/Definitions/tfile.yml index 5c33ce3a6..904a25ba7 100644 --- a/src/Jackett.Common/Definitions/tfile.yml +++ b/src/Jackett.Common/Definitions/tfile.yml @@ -1,4 +1,4 @@ ---- +--- site: tfile name: TFile description: "TFile is a RUSSIAN Public Torrent Tracker for MOVIES / TV / GENERAL" @@ -854,6 +854,7 @@ download: selector: a[href^="{{ .Config.downloadlink }}"] + attribute: href search: paths: @@ -923,4 +924,4 @@ text: 0 uploadvolumefactor: text: 1 -# engine n/a \ No newline at end of file +# engine n/a diff --git a/src/Jackett.Common/Definitions/the-madhouse.yml b/src/Jackett.Common/Definitions/the-madhouse.yml index 96628e8b3..917f9ad34 100644 --- a/src/Jackett.Common/Definitions/the-madhouse.yml +++ b/src/Jackett.Common/Definitions/the-madhouse.yml @@ -103,6 +103,7 @@ inputs: torrentid: "{{ .DownloadUri.Query.id }}" selector: a[href*="/download.php?id="] + attribute: href search: paths: diff --git a/src/Jackett.Common/Definitions/topnow.yml b/src/Jackett.Common/Definitions/topnow.yml index 1b6b3616a..d86d898e4 100644 --- a/src/Jackett.Common/Definitions/topnow.yml +++ b/src/Jackett.Common/Definitions/topnow.yml @@ -21,6 +21,8 @@ download: selector: a#torrent + attribute: href + search: paths: # http://topnow.se/search.php?dayq=mandalorian diff --git a/src/Jackett.Common/Definitions/toros.yml b/src/Jackett.Common/Definitions/toros.yml index 835e5ec9b..1beb7c97f 100644 --- a/src/Jackett.Common/Definitions/toros.yml +++ b/src/Jackett.Common/Definitions/toros.yml @@ -45,6 +45,7 @@ download: selector: a[href^="magnet:?xt="] + attribute: href search: paths: diff --git a/src/Jackett.Common/Definitions/torrent9.yml b/src/Jackett.Common/Definitions/torrent9.yml index dcd9933ed..5207b0e7f 100644 --- a/src/Jackett.Common/Definitions/torrent9.yml +++ b/src/Jackett.Common/Definitions/torrent9.yml @@ -55,7 +55,7 @@ download: selector: a[href^="magnet:?"] attribute: href - + search: paths: - path: "{{ if .Keywords }}/search_torrent/{{ re_replace .Keywords \"[']+\" \"\" }}/page-0{{else}}/top_torrent.html{{end}}" diff --git a/src/Jackett.Common/Definitions/torrentdownload.yml b/src/Jackett.Common/Definitions/torrentdownload.yml index ff8d2dc2a..bf79e4b46 100644 --- a/src/Jackett.Common/Definitions/torrentdownload.yml +++ b/src/Jackett.Common/Definitions/torrentdownload.yml @@ -40,6 +40,7 @@ download: selector: a[href^="magnet:?xt="] + attribute: href search: paths: diff --git a/src/Jackett.Common/Definitions/torrentdownloads.yml b/src/Jackett.Common/Definitions/torrentdownloads.yml index c6b0f2564..7c53ced77 100644 --- a/src/Jackett.Common/Definitions/torrentdownloads.yml +++ b/src/Jackett.Common/Definitions/torrentdownloads.yml @@ -36,6 +36,7 @@ download: selector: a[href^="{{ .Config.downloadlink }}"] + attribute: href search: paths: diff --git a/src/Jackett.Common/Definitions/torrentparadise.yml b/src/Jackett.Common/Definitions/torrentparadise.yml index 593223ab9..626f195ea 100644 --- a/src/Jackett.Common/Definitions/torrentparadise.yml +++ b/src/Jackett.Common/Definitions/torrentparadise.yml @@ -67,6 +67,7 @@ download: selector: a[href^="magnet:?xt="] + attribute: href search: # https://torrentparadise.org/search.php?f=monday+night diff --git a/src/Jackett.Common/Definitions/unlimitz.yml b/src/Jackett.Common/Definitions/unlimitz.yml index a55677b74..7881d9742 100644 --- a/src/Jackett.Common/Definitions/unlimitz.yml +++ b/src/Jackett.Common/Definitions/unlimitz.yml @@ -99,6 +99,7 @@ download: selector: a[href^="d.php?keyalert1="] + attribute: href filters: - name: replace args: ["d.php?keyalert1=", "/dI.php/"] diff --git a/src/Jackett.Common/Definitions/vanila.yml b/src/Jackett.Common/Definitions/vanila.yml index 90ab00469..0c1f2360a 100644 --- a/src/Jackett.Common/Definitions/vanila.yml +++ b/src/Jackett.Common/Definitions/vanila.yml @@ -1330,6 +1330,7 @@ download: selector: a[href^="./download/file.php?id="]:not(img) + attribute: href search: paths: diff --git a/src/Jackett.Common/Indexers/CardigannIndexer.cs b/src/Jackett.Common/Indexers/CardigannIndexer.cs index 91ae93d23..4847e0001 100644 --- a/src/Jackett.Common/Indexers/CardigannIndexer.cs +++ b/src/Jackett.Common/Indexers/CardigannIndexer.cs @@ -1734,13 +1734,23 @@ namespace Jackett.Common.Indexers if (response.IsRedirect) response = await RequestStringWithCookies(response.RedirectingTo); var results = response.Content; - var SearchResultParser = new HtmlParser(); - var SearchResultDocument = SearchResultParser.ParseDocument(results); - var DlUri = SearchResultDocument.QuerySelector(selector); - if (DlUri != null) + var searchResultParser = new HtmlParser(); + var searchResultDocument = searchResultParser.ParseDocument(results); + var downloadElement = searchResultDocument.QuerySelector(selector); + if (downloadElement != null) { - logger.Debug(string.Format("CardigannIndexer ({0}): Download selector {1} matched:{2}", ID, selector, DlUri.ToHtmlPretty())); - var href = DlUri.GetAttribute("href"); + logger.Debug(string.Format("CardigannIndexer ({0}): Download selector {1} matched:{2}", ID, selector, downloadElement.ToHtmlPretty())); + var href = ""; + if (Download.Attribute != null) + { + href = downloadElement.GetAttribute(Download.Attribute); + if (href == null) + throw new Exception(string.Format("Attribute \"{0}\" is not set for element {1}", Download.Attribute, downloadElement.ToHtmlPretty())); + } + else + { + href = downloadElement.TextContent; + } href = applyFilters(href, Download.Filters, variables); link = resolvePath(href, link); } diff --git a/src/Jackett.Common/Models/IndexerDefinition.cs b/src/Jackett.Common/Models/IndexerDefinition.cs index 5c592bbfa..a22bafff8 100644 --- a/src/Jackett.Common/Models/IndexerDefinition.cs +++ b/src/Jackett.Common/Models/IndexerDefinition.cs @@ -197,6 +197,7 @@ namespace Jackett.Common.Models public class downloadBlock { public string Selector { get; set; } + public string Attribute { get; set; } public List Filters { get; set; } public string Method { get; set; } public requestBlock Before { get; set; }