차이

문서의 선택한 두 판 사이의 차이를 보여줍니다.

차이 보기로 링크

양쪽 이전 판이전 판
다음 판
이전 판
tech:synology_dlm [2024/03/08 13:17] – 제거됨 - 바깥 편집 (Unknown date) 127.0.0.1tech:synology_dlm [2024/03/08 13:19] (현재) V_L
줄 1: 줄 1:
 +{{tag>torrentkim synology dlm}}
 +====== Synology download station .DLM ======
 +
 +=====1337x=====
 +
 +https://community.synology.com/enu/forum/1/post/186248
 +
 +
 +
 +=====Nyaa=====
 +
 +https://github.com/narsimplyme/Synology-DLM-for-nyaa
 +
 + 
 +=====magnetDL=====
 +
 +https://github.com/sgreadly/syno-ds-magnetdl-dlm/blob/main/MagnetDL_1.2.dlm
 +
 +
 +=====Torrentkim=====
 +
 +
 +[[tech:synology|]] 디스크스테이션의 다운로드스테이션에 커스텀 사이트를 등록할 수 있다.
 +DLM 파일을 작성하면 된다.
 +DLM 파일은 tar 형식으로 압축된 것이며 내부에 텍스트 문서가 있다. 
 +
 +  INFO
 +  search.php
 +
 +압축을 풀자. 
 +
 +<file  json INFO>
 +{
 +"name": "torrentkim",
 +"displayname": "TorrentKim10",
 +"description": "Korea Torrent Community",
 +"version": "1.0",
 +"majorversion": "4",
 +"minorversion": "10",
 +"minfirmware": "2257",
 +"min_dl_major_version": "3",
 +"min_dl_minor_version": "2",
 +"min_dl_build": "2356",
 +"site": "https://torrentkim10.net",
 +"module": "search.php",
 +"type": "search",
 +"class": "SynoDLMSearchTorrentKim"
 +}
 +
 +</file>
 +
 +<file  php search.php>
 +<?php
 +class SynoDLMSearchTorrentKim {
 + private $qurl = "https://torrentkim10.net/bbs/rss.php?k=";
 +
 + public function __construct() {
 + }
 +
 + public function prepare($curl, $query) {
 + $url = $this->qurl . urlencode($query);
 + curl_setopt($curl, CURLOPT_URL, $url);
 + }
 +
 + public function parse($plugin, $response) {
 + $response = preg_replace("/<pubDate>/i", "<pubDate>" . date("r"), $response);
 + $response = preg_replace("/<\/pubDate>/i", "</pubDate><category>All</category>", $response);
 + $response = preg_replace("/<description><\/description>/i", "<description><![CDATA[Category: All<br />Subcategory: All]]></description>", $response);
 + $response = preg_replace("/\&dn=.*?(?=&tr)/i", "", $response);
 + $response = preg_replace("/&/i", "%26", $response);
 + return $plugin->addRSSResults($response);
 + }
 +}
 +?>
 +
 +</file>
 +
 +문제는 토렌트킴의 주소가 계속 바뀐다는 거임.
 +