From c6bc744ca0eddfc463c0f50f467f1ef7d7deced7 Mon Sep 17 00:00:00 2001 From: Johan Andersson Date: Fri, 16 Sep 2011 17:35:18 +0200 Subject: [PATCH] Added support to download videos from tv8play --- svtplay-dl | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/svtplay-dl b/svtplay-dl index 44055f4..6f4a98b 100755 --- a/svtplay-dl +++ b/svtplay-dl @@ -84,6 +84,7 @@ class Viaplay(Common): if not self.output: self.output = os.path.basename(ss) print "Outfile: ", self.output + other = "-W http://flvplayer.viastream.viasat.tv/play/swf/player110516.swf?rnd=1315434062" self.getrtmp(ss, self.output, self.live, other) class Tv4play(Common): @@ -215,6 +216,16 @@ def main(): viaplay = Viaplay(output, quality, live) viaplay.get(url) + elif re.findall("tv8play", url): + parse = urlparse.urlparse(url) + match = re.search('\/play\/(.*)/', parse.path) + if not match: + print "Something wrong with that url" + sys.exit(2) + url = "http://viastream.viasat.tv/PlayProduct/%s" % match.group(1) + viaplay = Viaplay(output, quality, live) + viaplay.get(url) + else: svtplay = Svtplay(output, quality, live) svtplay.get(url)