LSP Regex & Makelist Discussion.

DarkSky

Member
Apr 1, 2016
42
0
6
no longer works :-(
can someone fix this?


Code:
<item>
<title>**https://www.canlitv.today/cartoon-network**</title>
<link>$doregex[getLink]|User-Agent=iPad</link>
<regex>
<name>getLink</name>
<expres>source src="(.*?)"</expres>
<page>https://www.canlitv.today/yayinim.php?kanal=cartoon-network</page>
<referer>https://www.canlitv.today/cartoon-network</referer>
<agent>Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:76.0) Gecko/20100101 Firefox/76.0</agent>
<cookieJar></cookieJar>
</regex>
</item>
 

peterpan

Active member
Jul 7, 2013
117
84
28
Ty this...
XML:
<item>
<title>CN --https://www.canlitv.today/cartoon-network--</title>
<link>$doregex[getUrl]|User-Agent=iPad</link>
<regex>
<name>getUrl</name>
<expres><![CDATA[#$pyFunction
def GetLSProData(page_data,Cookie_Jar,m):
  import re, requests, unwise
  source = requests.get('https://www.canlitv.today/yayinim.php?kanal=cartoon-network', headers={'user-agent':'Mozilla/5.0','referer':'https://www.canlitv.today/'}).text
  while 'w,i,s,e' in source:
    source=unwise.unwise_process(source)
  link = re.findall('attr\("src", "(.*?)"',source, re.DOTALL)[0]
  return link
]]></expres>
<page></page>
</regex>
</item>
 

tnico

New member
May 29, 2015
20
0
1
Can someone help me with this? Thanks hxxps://zonevideo.telequebec.tv/endirect/
 

streamwatcher2013

Well-known member
Oct 24, 2013
985
443
63
USA
Try this:

LSP XML code:
<item>
<title>Endirect</title>
<link>$doregex[getUrl]</link>
<regex>
<name>getUrl</name>
<expres><![CDATA[#$pyFunction
import re,requests
def GetLSProData(page_data,Cookie_Jar,m):#streamwatcher2013
  link=re.findall('src="(.*?player[^"]+)',page_data)[0]
  source=requests.get(link,headers={'user-agent':'Mozilla/5.0','referer':'https://zonevideo.telequebec.tv/endirect/'},cookies=Cookie_Jar).content
  return re.findall('l.{13,15}Url":"(\w[^"]+)',source)[0]+'|user-agent=ipad&referer='+link
]]></expres>
<page>https://zonevideo.telequebec.tv/endirect/</page>
<referer>https://zonevideo.telequebec.tv/</referer>
</regex>
<thumbnail>https://www.telequebec.tv/apple-touch-icon.png</thumbnail>
</item>
 

altug

Member
Jul 7, 2016
70
2
8
unfortunately no longer works, what do I have to change there

<item>
<title>atv</title>
<link>$doregex|Referer=https://7.fixspor45.xyz/</link> <regex> <name>url</name> <expres>window.mainSource\s=\s"(.*?)"</expres> <page>https://7.fixspor45.xyz/android/player2.php?id=atv</page> </regex> </item> [/QUOTE]
 

streamwatcher2013

Well-known member
Oct 24, 2013
985
443
63
USA
Nothing special

LSP XML code:
<item>
<title>aTV</title>
<link>$doregex[getUrl]</link>
<regex>
<name>getUrl</name>
<expres><![CDATA[#$pyFunction
import re
def GetLSProData(page_data,Cookie_Jar,m):#streamwatcher2013
  return re.findall('player[\w\W]*?(?:source|src|file):\s*[\'"]([^\'"]+)',page_data)[0]+'|user-agent=ipad&referer=https://7.fixspor45.xyz/player2.php?id=atv'
]]></expres>
<page>https://7.fixspor45.xyz/player2.php?id=atv</page>
<referer>https://7.fixspor45.xyz/</referer>
</regex>
</item>
 

Doom

Member
Sep 16, 2019
321
21
18

upd8t3r

Member
Oct 16, 2019
46
18
8
Code:
They're telerium streams. I know they've been considered too hard to regex, but I've gotten this far in figuring them out, maybe streamwatcher2013 can figure out how to make it work.


So for example this is one of the tv channels that are really just a telerium embed page.

https://telerium.tv/embed/55038.html


On that page is the eval(function(p,a,c,k,e,d) and when unpacked it looks like this. 
Lines 106 and 107 are what you need to get the link, if you base64 decode them and put them together, you just need to add https: in front and you've got your link. I just don't know how you'd be able to always find to find those 2 lines because I'm guessing those jumbled up looking letters that = the base64 encoded lines, probably change too.


esMobiliar=false;
if(/(android|bb\d+|meego).+mobile|avantgo|bada\/|blackberry|blazer|compal|elaine|fennec|hiptop|iemobile|ip(hone|od)|ipad|iris|kindle|Android|Silk|lge |maemo|midp|mmp|netfront|opera m(ob|in)i|palm( os)?|phone|p(ixi|re)\/|plucker|pocket|psp|series(4|6)0|symbian|treo|up\.(browser|link)|vodafone|wap|windows (ce|phone)|xda|xiino/i.test(navigator.userAgent)||/1207|6310|6590|3gso|4thp|50[1-6]i|770s|802s|a wa|abac|ac(er|oo|s\-)|ai(ko|rn)|al(av|ca|co)|amoi|an(ex|ny|yw)|aptu|ar(ch|go)|as(te|us)|attw|au(di|\-m|r |s )|avan|be(ck|ll|nq)|bi(lb|rd)|bl(ac|az)|br(e|v)w|bumb|bw\-(n|u)|c55\/|capi|ccwa|cdm\-|cell|chtm|cldc|cmd\-|co(mp|nd)|craw|da(it|ll|ng)|dbte|dc\-s|devi|dica|dmob|do(c|p)o|ds(12|\-d)|el(49|ai)|em(l2|ul)|er(ic|k0)|esl8|ez([4-7]0|os|wa|ze)|fetc|fly(\-|_)|g1 u|g560|gene|gf\-5|g\-mo|go(\.w|od)|gr(ad|un)|haie|hcit|hd\-(m|p|t)|hei\-|hi(pt|ta)|hp( i|ip)|hs\-c|ht(c(\-| |_|a|g|p|s|t)|tp)|hu(aw|tc)|i\-(20|go|ma)|i230|iac( |\-|\/)|ibro|idea|ig01|ikom|im1k|inno|ipaq|iris|ja(t|v)a|jbro|jemu|jigs|kddi|keji|kgt( |\/)|klon|kpt |kwc\-|kyo(c|k)|le(no|xi)|lg( g|\/(k|l|u)|50|54|\-[a-w])|libw|lynx|m1\-w|m3ga|m50\/|ma(te|ui|xo)|mc(01|21|ca)|m\-cr|me(rc|ri)|mi(o8|oa|ts)|mmef|mo(01|02|bi|de|do|t(\-| |o|v)|zz)|mt(50|p1|v )|mwbp|mywa|n10[0-2]|n20[2-3]|n30(0|2)|n50(0|2|5)|n7(0(0|1)|10)|ne((c|m)\-|on|tf|wf|wg|wt)|nok(6|i)|nzph|o2im|op(ti|wv)|oran|owg1|p800|pan(a|d|t)|pdxg|pg(13|\-([1-8]|c))|phil|pire|pl(ay|uc)|pn\-2|po(ck|rt|se)|prox|psio|pt\-g|qa\-a|qc(07|12|21|32|60|\-[2-7]|i\-)|qtek|r380|r600|raks|rim9|ro(ve|zo)|s55\/|sa(ge|ma|mm|ms|ny|va)|sc(01|h\-|oo|p\-)|sdk\/|se(c(\-|0|1)|47|mc|nd|ri)|sgh\-|shar|sie(\-|m)|sk\-0|sl(45|id)|sm(al|ar|b3|it|t5)|so(ft|ny)|sp(01|h\-|v\-|v )|sy(01|mb)|t2(18|50)|t6(00|10|18)|ta(gt|lk)|tcl\-|tdg\-|tel(i|m)|tim\-|t\-mo|to(pl|sh)|ts(70|m\-|m3|m5)|tx\-9|up(\.b|g1|si)|utst|v400|v750|veri|vi(rg|te)|vk(40|5[0-3]|\-v)|vm40|voda|vulc|vx(52|53|60|61|70|80|81|83|85|98)|w3c(\-| )|webc|whit|wi(g |nc|nw)|wmlb|wonu|x700|yas\-|your|zeto|zte\-/i.test(navigator.userAgent.substr(0,4)))
    {
    esMobiliar=true
}
isEdge=false;
if(document.documentMode||/Edge/.test(navigator.userAgent))
    {
    isEdge=true
}
var ua=navigator.userAgent.toLowerCase();
var isAndroid=ua.indexOf("android")>-1;
function dameVuelta(str)
    {
    return str.split("").reverse().join("")
}
bool=false;
function compareProducts(cname,cvalue,exdays)
    {
    var d=new Date();
    d.setTime(d.getTime()+(exdays*24*60*60*1000));
    var expires="expires="+d.toUTCString();
    document.cookie=cname+"="+cvalue+";
    "+expires+";
    path=/;
     SameSite=None;
     Secure"
};
function gladyouareHere(cname)
    {
    var name=cname+"=";
    var ca=document.cookie.split(";
    ");
    for(var i=0;
    i<ca.length;
    i++)
        {
        var c=ca[i];
        while(c.charAt(0)==" ")
            {
            c=c.substring(1)
        };
        if(c.indexOf(name)==0)
            {
            return c.substring(name.length,c.length)
        }
    };
    return""
};
if(document.cookie)
    {
    if(document.cookie.indexOf("elVolumen=")!=-1)
        {
    }
    else
        {
        compareProducts("elVolumen",100,365)
    }
}
else
    {
    compareProducts("elVolumen",100,365)
};
masita=gladyouareHere("elVolumen");
function errorPlaying()
    {
    $(".player-error-screen__code").html("Retrying in <span class='counter'>30</span> seconds.");
    var a=30;
    var refreshIntervalId=window.setInterval(function()
        {
        if(a>1)
            {
            a--;
            $(".player-error-screen__content .counter").text(a)
        }
        else
            {
            ErYAUzTAaE.play();
            clearInterval(refreshIntervalId);
            $(".player-error-screen__content .counter").text("30");
            $(".player-error-screen").css("display","none")
        }
    }
    ,1000)
}
streamdelay=500;
var lhddwPKRuc=12;
bhsgGQZanJ="Ly9lMS5jZG40LnVzL2luZ2VzdDAxMS81NTAzOC5tM3U4P3NmPVR6VTVObTl4YlUxdk5BPT0=";
jZyskdUiLM="Ly8xODczMDgzNzg3LnJzYy5jb250ZW50cHJveHk5LmN6L3RlbGUyLnBuZw==";
OzKydRxPkY="dG1zcFdQcVJkTmxFby9pbmdlc3QwMTEvNTUwMzgubTN1OD9zZj1UelU1Tm05eGJVMXZOQT09";
ydWEgiJGvN="Ly9lNS5jZG40LnVzL2luZ2VzdDAxMS81NTAzOC5tM3U4P3NmPVR6VTVObTl4YlUxdk5BPT0=";
var PUWpOwptQB=6;
fsjlEBXISJ="Y2hhbm5lbHN0cmVhbS5jbHVi";
var GsQnQAJMzy=13;
ZxKDgZMtAe="Ly9lNS5jZG40LnVzL2luZ2VzdDAxMS81NTAzOC5tM3U4P3NmPVR6VTVObTl4YlUxdk5BPT0=";
OzKydRxPkYa="JnRva2VuPUFSTnZ2NTN3dlhmdjRUX0Y3WGNMRXcmZXhwaXJlcz0xNTkxNzE0MTE5JnJuZD01NTAzOA==";
var LgxAxpEkAi=7;
var zMqCPNsAEM=3;
MMMIrTRaAm="";
CuHyJvVYOL=lhddwPKRuc-PUWpOwptQB;
AASYbpnFzO=LgxAxpEkAi-zMqCPNsAEM;
OYAeBqRUQw=CuHyJvVYOL+AASYbpnFzO;
function isInArray(value,array)
    {
    return array.indexOf(value)>-1
};
function extractHostname(url)
    {
    var hostname;
    if(url.indexOf("://")>-1)
        {
        hostname=url.split("/")[2]
    }
    else
        {
        hostname=url.split("/")[0]
    };
    hostname=hostname.split(":")[0];
    hostname=hostname.split("?")[0];
    return hostname
};
var hostname=extractHostname(document.referrer);
if(fsjlEBXISJ=="")fsjlEBXISJ=btoa(hostname);
var sCeYyNHlUf=window.atob(fsjlEBXISJ);
var ZSidFrylqU=sCeYyNHlUf.split(",");
if(isInArray(hostname,ZSidFrylqU))
    {
    if(esMobiliar)
        {
        ydWEgiJGvN=ZxKDgZMtAe
    };
    function changlasmuy(rambopot,ydWEgiJGvN,jZyskdUiLM)
        {
        var TlfmrMdqMr=window.atob(ydWEgiJGvN);
        var jZyskdUiLM=window.atob(jZyskdUiLM);
        var playerRendered=false;
        if(navigator.cookieEnabled)
            {
            $.ajax(
                {
                url:window.atob(OzKydRxPkY).slice(GsQnQAJMzy)+window.atob(OzKydRxPkYa),dataType:"json",async:true
            }
            ).done(function(lkGWJJNhyX)
                {
                setTimeout(function()
                    {
                    if(typeof(ga)=="undefined")
                        {
                        $(".stream-tracking").css("display","table");
                        alert("tracking disabled")
                    }
                    else
                        {
                        azdMiuGZvg=dameVuelta(lkGWJJNhyX[OYAeBqRUQw]);
                        TlfmrMdqMr+=azdMiuGZvg;
                        if(rambopot=="GB")
                            {
                            TlfmrMdqMr=window.atob(bhsgGQZanJ)+azdMiuGZvg
                        };
                        hysterical("",TlfmrMdqMr,jZyskdUiLM,rambopot)
                    }
                }
                ,2000)
            }
            )
        }
        else
            {
            $(".stream-cookies").css("display","table")
        }
    };
    function getRandomInt(min,max)
        {
        min=Math.ceil(min);
        max=Math.floor(max);
        return Math.floor(Math.random()*(max-min+1))+min
    };
    function hysterical(pejuca,rucucu,wat,rambopot)
        {
        console.log("starting");
        if(typeof p2pml!=="undefined")
            {
            if(!esMobiliar&&!isEdge)
                {
                var engine=new p2pml.hlsjs.Engine(
                    {
                    loader:
                        {
                        WaitForTracker:true,WaitForTrackerCounter:8000,
                    }
                }
                )
            }
            else if(isAndroid)
                {
 

saul2918888

New member
Jan 28, 2017
2
0
1
hello I need help with this link

Code:
https://vercanalestv1.com/ver-canal-estrenos-en-directo-y-online-las-24h/
 

streamwatcher2013

Well-known member
Oct 24, 2013
985
443
63
USA
Try this:

LSP XML code:
<item>
<title>Estrenos</title>
<link>$doregex[getUrl]</link>
<regex>
<name>getUrl</name>
<expres><![CDATA[#$pyFunction
import re,requests
def GetLSProData(page_data,Cookie_Jar,m):#streamwatcher2013
  url='https://vercanalestv1.com/'+re.findall('id=.video[\w\W]*?src="/([^"]+)',page_data)[0]
  source=requests.get(url,headers={'user-agent':'Mozilla/5.0','host':'vercanalestv1.com','referer':'https://vercanalestv1.com/ver-canal-estrenos-en-directo-y-online-las-24h/','accept':'*/*'},cookies=Cookie_Jar).content
  plink=re.findall('iframe.*?src="(.+live[^"]+)',source)[0];plink='https:'+plink if plink.startswith('//') else plink
  source=requests.get(plink,headers={'user-agent':'Mozilla/5.0','referer':url,'accept':'*/*'},cookies=Cookie_Jar).content
  pID=int(re.findall('Para\s*ver\s*el.+?(\d+)',source)[0]);data={'manzana66':pID}
  source=requests.post(plink,headers={'user-agent':'Mozilla/5.0','referer':url,'origin':'https://vergol.com','x-requested-with':'XMLHttpRequest','accept':'*/*'},data=data,cookies=Cookie_Jar).content
  m3u8=re.findall('player/player.js[\w\W]*?source:\s*[\'"]([^\'"]+)',source)[0];m3u8='https:'+m3u8 if m3u8.startswith('//') else m3u8
  return '%s|user-agent=ipad&origin=https://vergol.com&referer=%s'%(m3u8,plink)
]]></expres>
<page>https://vercanalestv1.com/ver-canal-estrenos-en-directo-y-online-las-24h/</page>
<referer>https://vercanalestv1.com/</referer>
</regex>
<thumbnail>https://vercanalestv1.com/imagenes/movistar-estrenos.jpg</thumbnail>
</item>
 

peterpan

Active member
Jul 7, 2013
117
84
28
Some of the channels on that site use different coding algorithms...Here it is with a couple of small tweaks to SW's code...

XML:
<item>
<title>LaLigaTV</title>
<link>$doregex[getUrl]</link>
<regex>
<name>getUrl</name>
<expres><![CDATA[#$pyFunction
import re,requests,jsunpack
def GetLSProData(page_data,Cookie_Jar,m):
  url='https://vercanalestv1.com/'+re.findall('id=.video[\w\W]*?src="/([^"]+)',page_data)[0]
  source=requests.get(url,headers={'user-agent':'Mozilla/5.0','host':'vercanalestv1.com','referer':'https://vercanalestv1.com/ver-laliga-tv-online-y-en-directo-las-24h-por-internet-gratis/','accept':'*/*'},cookies=Cookie_Jar).content
  plink=re.findall('iframe.*?src="(.+live[^"]+)',source)[0];plink='https:'+plink if plink.startswith('//') else plink
  source=requests.get(plink,headers={'user-agent':'Mozilla/5.0','referer':url,'accept':'*/*'},cookies=Cookie_Jar).content
  pID=int(re.findall('Para\s*ver\s*el.+?(\d+)',source)[0]);data={'manzana66':pID}
  source=requests.post(plink,headers={'user-agent':'Mozilla/5.0','referer':plink,'origin':'https://vergol.com','x-requested-with':'XMLHttpRequest','accept':'*/*'},data=data,cookies=Cookie_Jar).content
  iframe=re.findall('iframe src="(.*?)"',source)[0]
  source=requests.get(iframe,headers={'user-agent':'Mozilla/5.0','referer':plink,'accept':'*/*'},cookies=Cookie_Jar).content
  unpack=jsunpack.unpack(re.findall('(eval.*(?:m3u8|mp4).*)',source)[0])
  m3u8=re.findall('player(?s).+?source:"(.*?)"',unpack)[0];m3u8='https:'+m3u8 if m3u8.startswith('//') else m3u8
  return '%s|user-agent=ipad&origin=https://vergol.com&referer=%s'%(m3u8,plink)
]]></expres>
<page>https://vercanalestv1.com/ver-laliga-tv-online-y-en-directo-las-24h-por-internet-gratis/</page>
<referer>https://vercanalestv1.com/</referer>
</regex>
<thumbnail>http://worldsoccertalk.com/wp-content/uploads/2016/07/la-liga-logo.jpg</thumbnail>
</item>
 
  • Like
Reactions: tungbeng95

peterpan

Active member
Jul 7, 2013
117
84
28
Here you go...

XML:
<item>
<title>SCTV **https://www.vidio.com/live/204-sctv**</title>
<link>$doregex[makelist]</link>
<regex>
<name>makelist</name>
<expres><![CDATA[#$pyFunction
import re, requests
def GetLSProData(page_data,Cookie_Jar,m):
  hls=re.findall('data-vjs-clip-hls-url="(.*?)"',page_data)[0]
  url='https://www.vidio.com/live/204/tokens'
  source=requests.get(url,headers={'user-agent':'Mozilla/5.0','referer':'page_data'}).content
  return hls+'?'+re.findall('"token":"(.*?)"',source)[0].replace('\u0026','&')+'|user-agent=iPad'
]]></expres>
<page>https://www.vidio.com/live/204-sctv</page>
<referer>https://www.vidio.com/</referer>
</regex>
</item>
 
  • Like
Reactions: tungbeng95

tungbeng95

Member
Oct 25, 2018
391
15
18
I want to help more 2 regexs.Please & thanks!
hxxps://lnk.lt/video/info-tv-hd-kanalas-internetu/96749
hxxps://www.lrt.lt/mediateka/tiesiogiai/lrt-lituanica
 

peterpan

Active member
Jul 7, 2013
117
84
28
Here you go...

XML:
<item>
<title>Stratic LTR **www.lrt.lt/mediateka/tiesiogiai/lrt-lituanica**</title>
<link>https://lituanica-dvr.lrt.lt/lrt-ndvr/hls/lituanica_720p/index.m3u8|Referer=https://www.lrt.lt/mediateka/tiesiogiai/lrt-lituanica</link>
</item>

<item>
<title>LRT **lnk.lt/video/info-tv-hd-kanalas-internetu/96749**</title>
<link>$doregex[getUrl]</link>
<regex>
<name>getUrl</name>
<expres><![CDATA[#$pyFunction
import re, requests
def GetLSProData(page_data,Cookie_Jar,m):
  m3u8=re.findall('videoUrl":"(.*?)"',page_data)[0]
  tok=re.findall('"secureTokenParams":"(.*?)"',page_data)[0]
  #source=requests.get(url,headers={'user-agent':'Mozilla/5.0','referer':'page_data'}).content
  return m3u8+tok+'|user-agent=iPad'
]]></expres>
<page>https://lnk.lt/api/main/video-page/info-tv-hd-kanalas-internetu/96749/false</page>
<referer>https://lnk.lt/video/info-tv-hd-kanalas-internetu/96749</referer>
</regex>
</item>
 
  • Like
Reactions: tungbeng95

peterpan

Active member
Jul 7, 2013
117
84
28
Here you go... Channels take for ever to load, but they're both working. For the 2nd stream just change LTV1 to LTV2 in the <page>...</page>

XML:
<item>
<title>LTV **https://www.lrt.lt/mediateka/tiesiogiai/lrt-televizija**</title>
<link>$doregex[getUrl]|user-agent=iPad</link>
<regex>
<name>getUrl</name>
<expres><![CDATA[#$pyFunction
import re
def GetLSProData(page_data,Cookie_Jar,m):
  return re.findall('content":"(.*?)"',page_data)[0].replace('\/', '/')
]]></expres>
<page>https://www.lrt.lt/servisai/stream_url/live/get_live_url.php?channel=LTV1</page>
<referer>https://www.lrt.lt/mediateka/tiesiogiai/lrt-televizija</referer>
<agent>iPad</agent>
<x-req>XMLHttpRequest</x-req>
<cookieJar></cookieJar>
</regex>
</item>
 
  • Like
Reactions: tungbeng95

peterpan

Active member
Jul 7, 2013
117
84
28
Here you go...

XML:
<item>
<title>**https://www.vidio.com/premier/1381/insya-allah-surga-tingkat-2**</title>
<link>$doregex[makelist]</link>
<regex>
<name>makelist</name>
<listrepeat><![CDATA[
  <title>[COLOR gold][makelist.param3][/COLOR]</title>
  <link>$doregex[getUrl]</link>
  <thumbnail>[makelist.param2]</thumbnail>
]]></listrepeat>
<expres><![CDATA[#$pyFunction
import re
def GetLSProData(page_data,Cookie_Jar,m):
  return re.findall('profile-video__link" href="(.*?)"(?s).+?img data-src="(.*?)"(?s).+?alt="(.*?)"',page_data)
]]></expres>
<page>https://www.vidio.com/premier/1381/insya-allah-surga-tingkat-2</page>
</regex>
<regex>
<name>getUrl</name>
<expres><![CDATA[#$pyFunction
import re, requests
def GetLSProData(page_data,Cookie_Jar,m):
  return re.findall('data-vjs-clip-hls-url="(.*?)"',page_data)[0]+'|user-agent=iPad'
]]></expres>
<page>https://www.vidio.com[makelist.param1]</page>
<referer>https://www.vidio.com/premier/1381/insya-allah-surga-tingkat-2</referer>
</regex>
</item>
 

streamwatcher2013

Well-known member
Oct 24, 2013
985
443
63
USA
Try this:

LSP XML Code:
<item>
<title>Jodoh Yang Tertukar</title>
<link>$doregex[makelist]</link>
<regex>
<name>makelist</name>
<listrepeat><![CDATA[
  <title>[COLOR gold]Jodoh Yang Tertukar[/COLOR] ([makelist.param3])</title>
  <link>$doregex[getUrl]</link>
  <thumbnail>https:[makelist.param2]</thumbnail>
]]></listrepeat>
<expres><![CDATA["profile-video__link" href="([^"]+).+?data-src="([^"]+).+?video__title">([^<]+)]]></expres>
<page>https://www.vidio.com/premier/332</page>
</regex>
<regex>
<name>getUrl</name>
<expres><![CDATA[#$pyFunction
import re,requests
def GetLSProData(page_data,Cookie_Jar,m):#streamwatcher2013
  link=re.findall('data-vjs-clip-hls-url="([^"]+)',page_data)[0]
  source=requests.get(link,headers={'user-agent':'Mozilla/5.0','referer':'https://www.vidio.com/[makelist.param1]','accept':'*/*'}).content
  if '1024' in source:
    return re.findall('x576.+\n(.*)',source)[0]+'|user-agent=ipad&origin=https://www.vidio.com&referer=https://www.vidio.com/'
  elif '640' in source:
    return re.findall('x360.+\n(.*)',source)[0]+'|user-agent=ipad&origin=https://www.vidio.com&referer=https://www.vidio.com/'
  else:
    return re.findall('x270.+\n(.*)',source)[0]+'|user-agent=ipad&origin=https://www.vidio.com&referer=https://www.vidio.com/'
]]></expres>
<page>https://www.vidio.com/[makelist.param1]</page>
<referer>https://www.vidio.com/premier/332</referer>
</regex>
<thumbnail>https://cdn-production-thumbor-vidio.akamaized.net/uvv4_s4ScikO89G9cqWJB9cjpb8=/212x315/filters:quality(75)/vidio-web-prod-film/uploads/film/image_portrait/332/jodoh-yang-tertukar-cff877.jpg</thumbnail>
</item>
 

peterpan

Active member
Jul 7, 2013
117
84
28
@streamwatcher2013 Your "Jodoh Yang Tertukar" makelist is only able to retrieve 17 episodes. The series has 51 episodes. I have attempted to get all 51, but I'm not good at Python :(. So maybe you can edit/fix my code below to get it to work. I've tried "while..." and "for pn..." functions, but my code chokes. Thanks!

XML:
<item>
<title>Get All Episodes - Jodoh Yang Tertukar Series</title>
<link>$doregex[makelist]</link>
<regex>
<name>makelist</name>
<listrepeat><![CDATA[
  <title>JodohYang Tertukar - [COLOR blue][makelist.param3][/COLOR]</title>
  <link>$doregex[getUrl]</link>
  <thumbnail>[makelist.param2]</thumbnail>
]]></listrepeat>
<expres><![CDATA[#$pyFunction
import re,requests
def GetLSProData(page_data,Cookie_Jar,m):
  source=requests.get('https://www.vidio.com/premier/332',headers={'user-agent':'Mozilla/5.0','accept':'*/*'}).content
  nextSeriesID=re.findall('data-page-size.+data-playlist-id="(.*?)"',source)[0]
  lastpg=re.findall('.*data-page="(.+)".data-page-size',source)[0]
  count=2;pn=1;data=[]
  while pn <= int(count):
    source=requests.get('https://www.vidio.com/content_profiles/332/playlists/'+nextSeriesID+'/playlist_items.html?page='+str(pn),headers={'user-agent':'Mozilla/5.0','accept':'*/*'}).content
  return +=re.findall('profile-video__link.+?href="(.*?)"(?s).+?img.data-src="(.*?)"(?s).+?alt="(.*?)"',re.findall('data-type="cpp"(?s)(.*?)visibility..hidden;"'source)[0]);pn +=1
]]></expres>
<page>https://www.vidio.com/premier/332</page>
</regex>
</item>
 

streamwatcher2013

Well-known member
Oct 24, 2013
985
443
63
USA
@peterpan

Thanks to point that out. I did not pay attention much on get more list. Here it is

LSP XML Code:
<item>
<title>Jodoh Yang Tertukar</title>
<link>$doregex[makelist]</link>
<regex>
<name>makelist</name>
<listrepeat><![CDATA[
  <title>[COLOR gold]Jodoh Yang Tertukar[/COLOR] ([makelist.param3])</title>
  <link>$doregex[getUrl]</link>
  <thumbnail>https:[makelist.param2]</thumbnail>
]]></listrepeat>
<expres><![CDATA[#$pyFunction
import re,requests
def GetLSProData(page_data,Cookie_Jar,m):#streamwatcher2013
  source=requests.get('https://www.vidio.com/content_profiles/332/playlists/484/playlist_items.html?page=1&page_size=40',headers={'user-agent':'Mozilla/5.0','accept':'*/*'}).content
  return re.findall('"profile-video__link" href="([^"]+).+?data-src="([^"]+).+?video__title">([^<]+)',source)
]]></expres>
<page></page>
</regex>
<regex>
<name>getUrl</name>
<expres><![CDATA[#$pyFunction
import re,requests
def GetLSProData(page_data,Cookie_Jar,m):#streamwatcher2013
  link=re.findall('data-vjs-clip-hls-url="([^"]+)',page_data)[0]
  source=requests.get(link,headers={'user-agent':'Mozilla/5.0','referer':'https://www.vidio.com/[makelist.param1]','accept':'*/*'}).content
  if '1024' in source:
    return re.findall('x576.+\n(.*)',source)[0]+'|user-agent=ipad&origin=https://www.vidio.com&referer=https://www.vidio.com/'
  elif '640' in source:
    return re.findall('x360.+\n(.*)',source)[0]+'|user-agent=ipad&origin=https://www.vidio.com&referer=https://www.vidio.com/'
  else:
    return re.findall('x270.+\n(.*)',source)[0]+'|user-agent=ipad&origin=https://www.vidio.com&referer=https://www.vidio.com/'
]]></expres>
<page>https://www.vidio.com/[makelist.param1]</page>
<referer>https://www.vidio.com/premier/332</referer>
</regex>
<thumbnail>https://cdn-production-thumbor-vidio.akamaized.net/uvv4_s4ScikO89G9cqWJB9cjpb8=/212x315/filters:quality(75)/vidio-web-prod-film/uploads/film/image_portrait/332/jodoh-yang-tertukar-cff877.jpg</thumbnail>
</item>
 
  • Like
Reactions: peterpan

streamwatcher2013

Well-known member
Oct 24, 2013
985
443
63
USA
@peterpan

It is how those pages load by for and while.

multi Pages load:
<item>
<title>Get All Episodes - by FOR</title>
<link>$doregex[makelist]</link>
<regex>
<name>makelist</name>
<listrepeat><![CDATA[
  <title>JodohYang Tertukar - [COLOR blue][makelist.param3][/COLOR]</title>
  <link>$doregex[getUrl]</link>
  <thumbnail>[makelist.param2]</thumbnail>
]]></listrepeat>
<expres><![CDATA[#$pyFunction
import re,requests
def GetLSProData(page_data,Cookie_Jar,m):
  pID,page,plist,liD=re.findall('.+profile-id="(\d+).+?page="(\d+).+?size="(\d+).+?list-id="(\d+).></li></ul',page_data)[0]
  url='https://www.vidio.com/content_profiles/%s/playlists/%s/playlist_items.html?page='%(pID,liD)
  data=[];npage=int(page)+int(1)
  for pn in xrange(1,int(npage)):
    source=requests.get(url+str(pn)+'&page_size=%s'%plist,headers={'user-agent':'Mozilla/5.0','referer':'https://www.vidio.com/premier/332','accept':'*/*'}).content
    data +=re.findall('profile-video__link.+?href="(.*?)"(?s).+?img.data-src="(.*?)"(?s).+?alt="(.*?)"',source)  #use for for pn in xrange(1,int(npage)):
  return data
]]></expres>
<page>https://www.vidio.com/premier/332</page>
</regex>
</item>

<item>
<title>Get All Episodes - by FOR</title>
<link>$doregex[makelist]</link>
<regex>
<name>makelist</name>
<listrepeat><![CDATA[
  <title>JodohYang Tertukar - [COLOR blue][makelist.param3][/COLOR]</title>
  <link>$doregex[getUrl]</link>
  <thumbnail>[makelist.param2]</thumbnail>
]]></listrepeat>
<expres><![CDATA[#$pyFunction
import re,requests
def GetLSProData(page_data,Cookie_Jar,m):
  pID,page,plist,liD=re.findall('.+profile-id="(\d+).+?page="(\d+).+?size="(\d+).+?list-id="(\d+).></li></ul',page_data)[0]
  url='https://www.vidio.com/content_profiles/%s/playlists/%s/playlist_items.html?page='%(pID,liD);npage=int(page)+int(1)
  data=re.findall('profile-video__link.+?href="(.*?)"(?s).+?img.data-src="(.*?)"(?s).+?alt="(.*?)"',page_data)
  for pn in xrange(2,int(npage)):
    source=requests.get(url+str(pn)+'&page_size=%s'%plist,headers={'user-agent':'Mozilla/5.0','referer':'https://www.vidio.com/premier/332','accept':'*/*'}).content
    data +=re.findall('profile-video__link.+?href="(.*?)"(?s).+?img.data-src="(.*?)"(?s).+?alt="(.*?)"',source)
  return data
]]></expres>
<page>https://www.vidio.com/premier/332</page>
</regex>
</item>

<item>
<title>Get All Episodes -by WHILE</title>
<link>$doregex[makelist]</link>
<regex>
<name>makelist</name>
<listrepeat><![CDATA[
  <title>JodohYang Tertukar - [COLOR blue][makelist.param3][/COLOR]</title>
  <link>$doregex[getUrl]</link>
  <thumbnail>[makelist.param2]</thumbnail>
]]></listrepeat>
<expres><![CDATA[#$pyFunction
import re,requests
def GetLSProData(page_data,Cookie_Jar,m):
  pID,page,plist,liD=re.findall('.+profile-id="(\d+).+?page="(\d+).+?size="(\d+).+?list-id="(\d+).></li></ul',page_data)[0]
  url='https://www.vidio.com/content_profiles/%s/playlists/%s/playlist_items.html?page='%(pID,liD)
  data=[];npage=int(page)+int(1)
  count=npage;pn=1
  while pn <= int(count):
    source=requests.get(url+str(pn)+'&page_size=%s'%plist,headers={'user-agent':'Mozilla/5.0','referer':'https://www.vidio.com/premier/332','accept':'*/*'}).content
    data +=re.findall('profile-video__link.+?href="(.*?)"(?s).+?img.data-src="(.*?)"(?s).+?alt="(.*?)"',source);pn +=1
  return data
]]></expres>
<page>https://www.vidio.com/premier/332</page>
</regex>
</item>

<item>
<title>Get All Episodes - by WHILE</title>
<link>$doregex[makelist]</link>
<regex>
<name>makelist</name>
<listrepeat><![CDATA[
  <title>JodohYang Tertukar - [COLOR blue][makelist.param3][/COLOR]</title>
  <link>$doregex[getUrl]</link>
  <thumbnail>[makelist.param2]</thumbnail>
]]></listrepeat>
<expres><![CDATA[#$pyFunction
import re,requests
def GetLSProData(page_data,Cookie_Jar,m):
  pID,page,plist,liD=re.findall('.+profile-id="(\d+).+?page="(\d+).+?size="(\d+).+?list-id="(\d+).></li></ul',page_data)[0]
  url='https://www.vidio.com/content_profiles/%s/playlists/%s/playlist_items.html?page='%(pID,liD)
  mdata=re.findall('profile-video__link.+?href="(.*?)"(?s).+?img.data-src="(.*?)"(?s).+?alt="(.*?)"',page_data)
  count=int(page);pn=2;data=[]
  while pn <= int(count):
    source=requests.get(url+str(pn)+'&page_size=%s'%plist,headers={'user-agent':'Mozilla/5.0','referer':'https://www.vidio.com/premier/332','accept':'*/*'}).content
    data +=re.findall('profile-video__link.+?href="(.*?)"(?s).+?img.data-src="(.*?)"(?s).+?alt="(.*?)"',source);pn +=1
  return mdata+data
]]></expres>
<page>https://www.vidio.com/premier/332</page>
</regex>
</item>
 
  • Like
Reactions: boomski2

umonkey

Member
Sep 18, 2012
70
0
6
Is it just me or can anybody else open a YouTube playlist in LSPro?
have tried both
<link>plugin://plugin.video.youtube/channel/UCTtPd40aikv5DWdW3KGkrQA/playlist/PLPSHxXQpj5yffVFjI9CRdD0R1XvoKmyMo/</link>
and
<utube>PLPSHxXQpj5yffVFjI9CRdD0R1XvoKmyMo</utube>

Can anyone help? thanks
 

streamwatcher2013

Well-known member
Oct 24, 2013
985
443
63
USA
Sometime it needs to click it twice to get the full list


LSP XML code:
<item>
<title>Kid-e-Cats</title>
<link>$doregex[makelist]</link>
<regex>
<name>makelist</name>
<listrepeat><![CDATA[
  <title>[makelist.param1]</title>
  <urlsolve>https://www.youtube.com/watch?v=[makelist.param2]</urlsolve>
  <thumbnail>https://i.ytimg.com/vi/[makelist.param2]/hqdefault.jpg</thumbnail>
  <fanart>https://i.ytimg.com/vi/eKqAfZaHaqw/maxresdefault.jpg</fanart>
]]></listrepeat>
<expres><![CDATA[#$pyFunction
import re,urllib
def GetLSProData(page_data,Cookie_Jar,m):#streamwatcher2013
  source=urllib.urlopen('https://www.youtube.com/playlist?list=PLPSHxXQpj5yffVFjI9CRdD0R1XvoKmyMo').read().replace('amp;','').replace('#038;','').replace('&#39;','\'').replace('&quot;','"')
  vID=re.findall('data-video-id="([^"]+)',source)
  title=re.findall('data-title="([^"]+)',source)
  return zip(title,vID)
]]></expres>
<page></page>
</regex>
<thumbnail>https://tnp.media/media/image/2019/5/c194ff1a-cea6-4e17-b829-650222fc6528.jpeg</thumbnail>
<fanart>https://i.ytimg.com/vi/eKqAfZaHaqw/maxresdefault.jpg</fanart>
</item>





<item>
<title>Kid-e-Cats</title>
<link>$doregex[makelist]</link>
<regex>
<name>makelist</name>
<listrepeat><![CDATA[
  <title>[makelist.param1]</title>
  <link>$doregex[getUrl]</link>
  <thumbnail>https://i.ytimg.com/vi/[makelist.param2]/hqdefault.jpg</thumbnail>
  <fanart>https://i.ytimg.com/vi/eKqAfZaHaqw/maxresdefault.jpg</fanart>
]]></listrepeat>
<expres><![CDATA[#$pyFunction
import re,urllib2
def GetLSProData(page_data,Cookie_Jar,m):#streamwatcher2013
  source=urllib2.urlopen('https://www.youtube.com/playlist?list=PLPSHxXQpj5yffVFjI9CRdD0R1XvoKmyMo').read().replace('amp;','').replace('&#39;','\'')
  vID=re.findall('data-video-id="([^"]+)',source)
  title=re.findall('data-title="([^"]+)',source)
  return zip(title,vID)
]]></expres>
<page></page>
</regex>
<regex>
<name>getUrl</name>
<expres><![CDATA[#$pyFunction
import resolveurl
def GetLSProData(page_data,Cookie_Jar,m):#streamwatcher2013
  return resolveurl.resolve('https://www.youtube.com/watch?v=[makelist.param2]')
]]></expres>
<page></page>
</regex>
<thumbnail>https://tnp.media/media/image/2019/5/c194ff1a-cea6-4e17-b829-650222fc6528.jpeg</thumbnail>
<fanart>https://i.ytimg.com/vi/eKqAfZaHaqw/maxresdefault.jpg</fanart>
</item>
 

umonkey

Member
Sep 18, 2012
70
0
6
Thanks, could maybe look at this


Code:
<item>
    <title>Blaze</title>
    <link>plugin://plugin.video.WatchNi****ns2/?action=actionEpisodesMenu&amp;url=https%3a%2f%2fwww.thewatchcartoononline.tv%2fanime%2fblaze-and-the-monster-machines</link>
    <NOTPlayable>True</NOTPlayable>
    <thumbnail>https://www.thetvdb.com/banners/posters/282747-1.jpg</thumbnail>
    <fanart>https://images.justwatch.com/backdrop/69767891/s1440/bing</fanart>
</item>
 

tungbeng95

Member
Oct 25, 2018
391
15
18
@peterpan can you help me this again? url always change...
11/6: hxxps://lnk.lt/video/info-tv-hd-kanalas-internetu/96749
12/6: hxxps://lnk.lt/video/info-tv-hd-kanalas-internetu/96750
13/6: hxxps://lnk.lt/video/info-tv-hd-kanalas-internetu/95339
 

peterpan

Active member
Jul 7, 2013
117
84
28
@tungbeng95 First I must be able to open the video you're interested in! For example when I try to play this lnk.lt/video/info-tv-hd-kanalas-internetu/96749 it just takes me to the main page. So I cannot even find the video you're interested in!
 
  • Like
Reactions: tungbeng95

streamwatcher2013

Well-known member
Oct 24, 2013
985
443
63
USA
Either one you like

LSP XML Code:
<item>
<title>INFO TV HD kanalas internetu!</title>
<link>$doregex[getUrl]</link>
<regex>
<name>getUrl</name>
<expres><![CDATA[#$pyFunction
import re,requests
def GetLSProData(page_data,Cookie_Jar,m):
  cID,path=re.findall('"id":(\d+),"title":"INFO TV HD.+?"urlSegment":"([^"]+)',page_data)[0]
  url='https://lnk.lt/api/main/video-page/%s/%s/false'%(path,int(cID))
  source=requests.get(url,headers={'user-agent':'Mozilla/5.0','host':'lnk.lt','referer':'https://lnk.lt/','accept':'*/*'},cookies=Cookie_Jar).content
  html,tok=re.findall('"video(?:U|u)rl":"(https://[^"]+)[\w\W]*?"secure(?:T|t)oken(?:P|p)arams":"([^"]+)',source)[0]
  return html+tok+'|user-agent=ipad&referer='+url
]]></expres>
<page>https://lnk.lt/api/main/landing-page</page>
<referer>https://lnk.lt/</referer>
</regex>
<thumbnail>https://lnk.lt/all-images/20200108/info1440x810_1c03253c-35dd-46eb-8d05-b49c88783201.jpg</thumbnail>
</item>


<item>
<title>TIESIO</title>
<link>$doregex[makelist]</link>
<regex>
<name>makelist</name>
<listrepeat><![CDATA[
  <title>[COLOR gold][makelist.param2][COLOR dodgerblue] ([makelist.param3])[/COLOR]</title>
  <link>$doregex[getUrl]</link>
  <thumbnail>https://lnk.lt/[makelist.param5]</thumbnail>
]]></listrepeat>
<expres><![CDATA[#$pyFunction
import json
def GetLSProData(page_data,Cookie_Jar,m):#streamwatcher2013
  jdata=json.loads(page_data)['videoGridCurrentLive']['videos']
  lists=[]
  for j in jdata:
    cid=str(j['id']);title=j['title'];adate=j['airDateText']
    path=j['urlSegment'];thumb=j['posterImage']
    lists.append((cid,title,adate,path,thumb))
  return lists
]]></expres>
<page>https://lnk.lt/api/main/live-page</page>
<referer>https://lnk.lt/</referer>
</regex>
<regex>
<name>getUrl</name>
<expres><![CDATA[#$pyFunction
import re
def GetLSProData(page_data,Cookie_Jar,m):
  html,tok=re.findall('videoUrl":"([^"]+)[\w\W]*?secureTokenParams":"([^"]+)',page_data)[0]
  return '%s%s|user-agent=ipad&referer=https://lnk.lt/api/main/video-page/[makelist.param4]/[makelist.param1]/false'%(html,tok)
]]></expres>
<page>https://lnk.lt/api/main/video-page/[makelist.param4]/[makelist.param1]/false</page>
<referer>https://lnk.lt/</referer>
</regex>
<thumbnail>https://lnk.lt/all-images/20200108/info1440x810_1c03253c-35dd-46eb-8d05-b49c88783201.jpg</thumbnail>
</item>
 
  • Like
Reactions: tungbeng95

Doom

Member
Sep 16, 2019
321
21
18

streamwatcher2013

Well-known member
Oct 24, 2013
985
443
63
USA
It's a simple one with base64

LSP XML Code:
<item>
<title>UFC Fight Night: Eye vs Calvillo MMA</title>
<link>$doregex[getUrl]</link>
<regex>
<name>getUrl</name>
<expres><![CDATA[#$pyFunction
import re,requests
def GetLSProData(page_data,Cookie_Jar,m):#streamwatcher2013
  link=re.findall('<iframe.+?src="([^"]+)',page_data)[0]
  source=requests.get(link,headers={'user-agent':'Mozilla/5.0','referer':'http://crackstreams.com/mmastreams/watch-ufc-eye-vs-calvillo/','accept':'*/*'}).content
  return re.findall('atob.[\'"]([^\'"]+)',source)[0].decode('base64')+'|user-agent=ipad&origin=http://nbastreams123.xyz&referer='+link
]]></expres>
<page>http://crackstreams.com/mmastreams/watch-ufc-eye-vs-calvillo/</page>
</regex>
</item>
 
  • Like
Reactions: Doom

gladio

New member
Oct 14, 2018
24
3
3
posso ottenere questo e grazie!
 
Last edited by a moderator:

streamwatcher2013

Well-known member
Oct 24, 2013
985
443
63
USA
Try this:

LSP XML Code:
<item>
<title>Телеканал: MCM Top онлайн</title>
<link>$doregex[getUrl]</link>
<regex>
<name>getUrl</name>
<expres><![CDATA[#$pyFunction
import re,requests
def GetLSProData(page_data,Cookie_Jar,m):#streamwatcher2013
  tok=re.findall('kes:[\'"]([^\'"]+)',page_data)[0]
  source=requests.get('http://ontivi.net/open?kes='+tok,headers={'user-agent':'Mozilla/5.0','host':'ontivi.net','referer':'http://ontivi.net/mcm-toptv.html','x-requested-with':'XMLHttpRequest','accept':'*/*'}).content.replace('//UlJSUlJS','').replace('//NTU1U1NT','').replace('//VFRUVFRU','').replace('//RERERERE','').replace('//RlZGVkZW','')
  return re.findall('id="plok[\w\W]*?file:.+?\#\d([^\'"]+)',source)[0].decode('base64')+'|user-agent=ipad&referer=http://ontivi.net/mcm-toptv.html'
]]></expres>
<page>http://ontivi.net/mcm-toptv.html</page>
<referer>http://ontivi.net/</referer>
</regex>
<thumbnail>http://ontivi.net/img/mcm-top.png</thumbnail>
</item>
 
  • Like
Reactions: gladio

peterpan

Active member
Jul 7, 2013
117
84
28
Here you go...

XML:
<item>
<title>Canal+ **https://nowagoal.xyz/embed/ch73.php**</title>
<link>$doregex[getUrl]</link>
<regex>
<name>getUrl</name>
<expres><![CDATA[#$pyFunction
import re,requests,jsunpack
def GetLSProData(page_data,Cookie_Jar,m):
  link=re.findall('iframe src="(.*?)"',page_data)[0]
  source=requests.get(link,cookies=Cookie_Jar,headers={'user-agent':'Mozilla/5.0','referer':'https://nowagoal.xyz/embed/ch73.php','host':'wstream.to','accept':'*/*'}).content
  decoded=jsunpack.unpack(re.findall('(eval.*(?:m3u8|mp4).*)',source)[0])
  return re.findall('mpegurl",src:"(.*?)"',decoded)[0]
]]></expres>
<page>https://nowagoal.xyz/embed/ch73.php</page>
</regex>
</item>
 
  • Like
Reactions: tungbeng95
Thread starter Similar threads Forum Replies Date
G Scraper Development 0
J Scraper Development 1
O Addon Requests 5