From e9e7a421ffa1f29236985ab91a45f72ed9e93c02 Mon Sep 17 00:00:00 2001 From: Mitsukarenai Date: Sun, 6 Dec 2015 15:55:47 +0100 Subject: [PATCH] (merge control) --- bridges/CpasbienBridge.php | 35 +++++++++++++++++++++-------------- 1 file changed, 21 insertions(+), 14 deletions(-) diff --git a/bridges/CpasbienBridge.php b/bridges/CpasbienBridge.php index c0acffb..220da91 100644 --- a/bridges/CpasbienBridge.php +++ b/bridges/CpasbienBridge.php @@ -1,16 +1,4 @@ maintainer = "lagaisse"; + $this->name = "Cpasbien Bridge"; + $this->uri = "http://Cpasbien.pw/"; + $this->description = "Returns latest torrent from request query"; + $this->update = "2015-05-17"; + + $this->parameters[] = + '[ + { + "name" : "keyword", + "identifier" : "q" + } + ]'; + + } + + public function collectData(array $param){ $html = ''; if (isset($param['q'])) { /* keyword search mode */ $this->request = str_replace(" ","-",trim($param['q'])); - $html = file_get_html('http://www.cpasbien.io/recherche/'.urlencode($this->request).'.html') or $this->returnError('No results for this query.', 404); + $html = file_get_html('http://www.cpasbien.pw/recherche/'.urlencode($this->request).'.html') or $this->returnError('No results for this query.', 404); } else { $this->returnError('You must specify a keyword (?q=...).', 400); @@ -74,7 +81,7 @@ class CpasbienBridge extends HttpCachingBridgeAbstract{ } public function getURI(){ - return 'http://www.cpasbien.io'; + return 'http://www.cpasbien.pw'; } public function getCacheDuration(){