From 44d3771ddeb26a302a1b799645b9ae6644460531 Mon Sep 17 00:00:00 2001 From: Intel1 <25161862+Intel11@users.noreply.github.com> Date: Wed, 4 Oct 2017 15:19:37 -0500 Subject: [PATCH] Update flashx.py --- plugin.video.alfa/servers/flashx.py | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/plugin.video.alfa/servers/flashx.py b/plugin.video.alfa/servers/flashx.py index 69ad0430..2d6eed50 100644 --- a/plugin.video.alfa/servers/flashx.py +++ b/plugin.video.alfa/servers/flashx.py @@ -37,17 +37,18 @@ def get_video_url(page_url, premium=False, user="", password="", video_password= flashx_id = scrapertools.find_single_match(data, 'name="id" value="([^"]+)"') fname = scrapertools.find_single_match(data, 'name="fname" value="([^"]+)"') hash_f = scrapertools.find_single_match(data, 'name="hash" value="([^"]+)"') - post = 'op=download1&usr_login=&id=%s&fname=%s&referer=&hash=%s&imhuman=Proceed to the video' % ( - flashx_id, urllib.quote(fname), hash_f) + imhuman = scrapertools.find_single_match(data, "value='([^']+)' name='imhuman'") + post = 'op=download1&usr_login=&id=%s&fname=%s&referer=&hash=%s&imhuman=%s' % ( + flashx_id, urllib.quote(fname), hash_f, imhuman) wait_time = scrapertools.find_single_match(data, "(\d+)") headers['Referer'] = "https://www.flashx.tv/" headers['Accept'] = "*/*" headers['Host'] = "www.flashx.tv" - coding_url = 'https://www.flashx.tv/flashx.php?fxfx=5' + coding_url = 'https://www.flashx.tv/flashx.php?fxfx=7' headers['X-Requested-With'] = 'XMLHttpRequest' - httptools.downloadpage(coding_url, headers=headers, replace_headers=True) + httptools.downloadpage(coding_url, headers=headers) try: time.sleep(int(wait_time) + 1)