---
id: diablotorrent
name: Diablo Torrent
description: "Diablo Torrent is a HUNGARIAN Private Torrent Tracker for MOVIES / TV / GENERAL"
language: hu-HU
type: private
encoding: UTF-8
requestDelay: 2
links:
  - https://diablotorrent.net/

caps:
  # dont forget to update the path categories in the search block
  categorymappings:
    # Film
    - {id: 49, cat: Movies/SD, desc: "Film > Cam", default: true}
    - {id: 21, cat: Movies/SD, desc: "Film > Cam [magyar]", default: true}
    - {id: 101, cat: Movies/SD, desc: "Film > SD/HUN", default: true}
    - {id: 102, cat: Movies/SD, desc: "Film > SD/ENG", default: true}
    - {id: 103, cat: Movies/HD, desc: "Film > HD/HUN", default: true}
    - {id: 104, cat: Movies/HD, desc: "Film > HD/ENG", default: true}
    - {id: 105, cat: Movies/DVD, desc: "Film > DVD-R/HUN", default: true}
    - {id: 106, cat: Movies/DVD, desc: "Film > DVD-R/ENG", default: true}
    # Sorozat
    - {id: 107, cat: TV/SD, desc: "Sorozat > SD/HUN", default: true}
    - {id: 108, cat: TV/SD, desc: "Sorozat > SD/ENG", default: true}
    - {id: 109, cat: TV/SD, desc: "Sorozat > DVD-R/HUN", default: true}
    - {id: 110, cat: TV/SD, desc: "Sorozat > DVD-R/ENG", default: true}
    - {id: 111, cat: TV/HD, desc: "Sorozat > HD/HUN", default: true}
    - {id: 112, cat: TV/HD, desc: "Sorozat > HD/ENG", default: true}
    # Pornó
    - {id: 34, cat: XXX/DVD, desc: "Pornó > DVD-R", default: false}
    - {id: 36, cat: XXX, desc: "Pornó > Képek", default: false}
    - {id: 113, cat: XXX/XviD, desc: "Pornó > SD", default: false}
    - {id: 114, cat: XXX, desc: "Pornó > HD", default: false}
    # Játék
    - {id: 12, cat: PC/Games, desc: "Játék > PC", default: true}
    - {id: 14, cat: Console/PS4, desc: "Játék > PS", default: true}
    - {id: 39, cat: Console/XBox, desc: "Játék > Xbox", default: true}
    - {id: 40, cat: Console/Other, desc: "Játék > Egyéb", default: true}
    # Zene
    - {id: 8, cat: Audio/MP3, desc: "Zene > MP3", default: true}
    - {id: 9, cat: Audio/MP3, desc: "Zene > MP3 [magyar]", default: true}
    - {id: 37, cat: Audio/Lossless, desc: "Zene > Lossless [magyar]", default: true}
    - {id: 38, cat: Audio/Lossless, desc: "Zene > Lossless", default: true}
    # Programok
    - {id: 16, cat: PC/0day, desc: "Programok > PC", default: true}
    - {id: 24, cat: PC/Mobile-Other, desc: "Programok > Mobil", default: true}
    - {id: 53, cat: PC/0day, desc: "Programok > Egyéb", default: true}
    # Egyéb
    - {id: 27, cat: Other, desc: "Egyéb > !! Feltöltési segédlet !!", default: true}
    - {id: 29, cat: Other, desc: "Egyéb > Képek", default: true}
    # E-Book
    - {id: 20, cat: Books, desc: "E-Book > Magyar", default: true}
    - {id: 52, cat: Books, desc: "E-Book > Egyéb", default: true}

  modes:
    search: [q]
    tv-search: [q, season, ep, imdbid]
    movie-search: [q, imdbid]
    music-search: [q]
    book-search: [q]

settings:
  - name: username
    type: text
    label: Username
  - name: password
    type: password
    label: Password
  - name: sort
    type: select
    label: Sort requested from site
    default: 7
    options:
      1: title
      7: created
      4: seeders
      2: size
  - name: type
    type: select
    label: Order requested from site
    default: desc
    options:
      desc: desc
      asc: asc
  - name: info_tpp
    type: info
    label: Results Per Page
    default: For best results, change the <b>Torrent oldalanként:</b> setting to <b>100</b> on your account profile.

login:
  path: login
  submitpath: login/run
  method: form
  inputs:
    referer: ""
    nev: "{{ .Config.username }}"
    jelszo: "{{ .Config.password }}"
    fsv: 0
    login: 1
    belepes: 1
    rhash: 123
  error:
    - selector: :root:contains("{\"hiba\":true,")
  test:
    path: browse
    selector: a[href*="logout"]

search:
  paths:
    - path: browse
      categories: [49, 21, 101, 102, 103, 104, 105, 106, 107, 108, 109, 110, 111, 112, 12, 14, 39, 40, 8, 9, 37, 38, 16, 24, 53, 27, 29, 20, 52]
    - path: browse/1
      categories: [34, 36, 113, 114]
  inputs:
    $raw: "{{ range .Categories }}category[]={{.}}&{{end}}"
    search: "{{ if .Query.IMDBID }}{{ .Query.IMDBID }}{{ else }}{{ .Keywords }}{{ end }}"
    imdb: "{{ if .Query.IMDBID }}1{{ else }}{{ end }}"
    s_alapjan: "{{ .Config.sort }}"
    s_sorrend: "{{ .Config.type }}"

  rows:
    selector: div.torrent_row, div.torrent_details
    after: 1

  fields:
    category:
      selector: div.box_category > img
      attribute: onclick
      filters:
        - name: regexp
          args: "category\\((\\d+),\\d+\\);"
    title:
      selector: a.box_name_a > span
    details:
      selector: a.box_name_a
      attribute: href
    download:
      selector: div.box_download > a
      attribute: href
    seeders:
      selector: div.box_seeders
    leechers:
      selector: div.box_leechers
    grabs:
      selector: div.box_completed
    files:
      selector: div.box_files
    date:
      selector: div.box_uploaded
      filters:
        - name: append
          args: " +01:00" # CET
        - name: dateparse
          args: "yyyy-MM-ddHH:mm:ss zzz"
    size:
      selector: div.box_size
    poster:
      selector: a.cover_a
      attribute: title
      filters:
        - name: regexp
          args: src='(.*?)'
    imdbid:
      selector: a[href*="imdb.com/title/tt"]
      attribute: href
    description_text:
      selector: div.torrent_row_magyarcim
      remove: span.torrent_row_new
    description:
      case:
        img[src="/pic/browse/yes.png"]: "Verified: {{ .Result.description_text}}"
        "*": "Unverified: {{ .Result.description_text}}"
    downloadvolumefactor:
      text: 1
    uploadvolumefactor:
      text: 1
    minimumseedtime:
      # 2 days (as seconds = 2 x 24 x 60 x 60)
      text: 172800
# engine tbd
