LSP Regex & Makelist Discussion.

m5Germany

Active member
Mar 20, 2014
203
56
28
Figured out what makes LSP3 show parse error while Code is Good when using XmlLint to check.
In the <title> I use • it throws the error. Switch • to | and Code works. Found that interesting.
LSP3 XML:
<item>
<title><![CDATA[[COLOR=red]•[/COLOR]]]></title>
<fanart></fanart>
<thumbnail></thumbnail>
<link></link>
<page></page>
</item>
 

JonnyB

New member
Oct 8, 2016
23
6
3
Hi,

I've notice that too, the symbols must be in unicode and must be inside a python block or it will not show correctly, if u want symbols in title call a regex:

\u25CF is for ●

XML:
<regex>
<name>symbol</name>
<expres><![CDATA[#$pyFunction     
def GetLSProData(page_data,Cookie_Jar,m):   
 return '\u25CF'
]]></expres>
<page></page>
</regex>
Don't know if there is an easier way but it's what I found as a solution.
 

JonnyB

New member
Oct 8, 2016
23
6
3
Hi,

I've notice that too, the symbols must be in unicode and must be inside a python block or it will not show correctly, if u want symbols in title call a regex:

\u25CF is for ●

XML:
<regex>
<name>symbol</name>
<expres><![CDATA[#$pyFunction    
def GetLSProData(page_data,Cookie_Jar,m):  
return '\u25CF'
]]></expres>
<page></page>
</regex>
Don't know if there is an easier way but it's what I found as a solution.

In my case if I insert "●" in the title, with or without CDATA tag, it will show "â", with the regex it shows the "●".
 
  • Like
Reactions: m5Germany

undpnd tqucbo

Member
Jan 25, 2021
49
0
6
I need help a site plz & tk
Code:
https://www.zeebiz.com/live-tv
 

m5Germany

Active member
Mar 20, 2014
203
56
28
LSP3 XML:
<item>
<title>Business News Live | zeebiz.com</title>
<link>$doregex[server]$doregex[token]|User-Agent=iPad&amp;Referer=https://www.zeebiz.com/</link>
<fanart></fanart>
<thumbnail></thumbnail>
<regex>
<name>token</name>
<expres>token":"([^"]+)</expres>
<page>https://useraction.zee5.com/token/live.php</page>
<referer>https://www.zeebiz.com/</referer>
</regex>
<regex>
<name>server</name>
<expres>stream_url":"([^"]+)</expres>
<page>https://s3-ap-southeast-1.amazonaws.com/vidgyor.com/live/midroll/run/zee_business.json?cb=144937</page>
<referer>https://www.zeebiz.com/</referer>
</regex>
</item>
 
  • Like
Reactions: undpnd tqucbo

m5Germany

Active member
Mar 20, 2014
203
56
28
Initial Menu appears as expected. Click to access channels makes Code Fail. Works in 18.5 and not LSP3.
Thanks, m5
LSP XML:
<item>
<title>[COLOR=FF00FFFF]Main Menu [COLOR red]|[/COLOR][COLOR=FF00CCFF] daddylive.co[/COLOR][/COLOR]</title>
<thumbnail>https://i.imgur.com/8EL6mr3.png</thumbnail>
<fanart>https://ohcbrands.com/wp-content/uploads/2018/05/black-background.jpg</fanart>
<link>$doregex[leg]</link>
<regex>
<name>leg</name>
<listrepeat><![CDATA[
<title>[COLOR=FF00FFFF][leg.param3][COLOR red]|[/COLOR][COLOR=FF00CCFF] daddylive.co[/COLOR][/COLOR]</title>
<thumbnail>https://i.imgur.com/8EL6mr3.png</thumbnail>
<fanart>https://ohcbrands.com/wp-content/uploads/2018/05/black-background.jpg</fanart>
<link>$doregex[getUrl]</link>
]]></listrepeat>
<expres><![CDATA[#$pyFunction
import re,requests
def GetLSProData(page_data,Cookie_Jar,m):
  source=requests.get('https://daddylive.co/24-hours-channels.php',headers={'Referer':'https://daddylive.club/','User-Agent':'Mozilla/5.0'}).content
  return re.findall('href="(/channels/stream-((?!46|76|77|86|87|88|89|51|55|58|59|67|68|69|70)\d\d).*?[^"]+).*\n.*?i>\s*(([^<]+))\s<',re.findall('<h3>(?s)(.*?)<div',source)[0])
]]></expres>
<page></page>
</regex>
<regex>
<name>getUrl</name>
<expres><![CDATA[#$pyFunction
import re,requests,jsunpack
def GetLSProData(page_data,Cookie_Jar,m):
  url=re.findall('iframe\s*src="([^"]+)',page_data)[0];url='https:'+url if url.startswith('//') else url
  source=requests.get(url,headers={'user-agent':'Mozilla/5.0','referer':'https://daddylive.club/','accept':'*/*'}).content
  m3u8=jsunpack.unpack(re.findall('(eval.*(?:m3u8|mp4).*)',source)[0])
  return re.findall('player[\w\W]*?source:\s*"([^"]+)',m3u8)[0]+'|user-agent=Mozilla/5.0&referer=https://wigistream.to/'
]]></expres>
<page>https://daddylive.co/[leg.param1]</page>
<referer>https://daddylive.co/</referer>
</regex>
</item>
 

Doom

Member
Sep 16, 2019
268
21
18
@streamwatcher2013 @m5Germany @gujal Only works in 18... in 19 loads but won't play and thanks!
<item>
<title>[COLOR gold]BOXING EVENTS[/COLOR]</title>
<thumbnail></thumbnail>
<fanart></fanart>
<link>$doregex[makelist]</link>
<regex>
<name>makelist</name>
<listrepeat><![CDATA[
<title>[COLOR blue][makelist.param3][/COLOR][COLOR white] - [/COLOR][COLOR gold][makelist.param2][/COLOR]</title>
<link>$doregex[getUrl]</link>
<thumbnail></thumbnail>
<fanart></fanart>
]]></listrepeat>
<expres><![CDATA[href=[\'"](.+?boxingstreams/watch[^\'"]+)[\w\W]+?media-heading.>([^<]+)[\w\W]+?<p>([^<]+)]]></expres>
<page>http://crackstreams.is/boxingstreams/</page>
</regex>
<regex>
<name>getUrl</name>
<expres><![CDATA[#$pyFunction
import re,requests
def GetLSProData(page_data,Cookie_Jar,m):#streamwatcher2013
source=requests.get('[makelist.param1]video.php',headers={'user-agent':'Mozilla/5.0','referer':'[makelist.param1]','accept':'*/*'}).content
if 'window.atob' in source:
return re.findall('window.atob.[\'"]([^\'"]+)',source)[0].decode('base64')+'|user-agent=ipad&origin=http://crackstreams.is&referer=[makelist.param1]video.php'
else:
return re.findall('id="play[\w\W]+?(?:source|src|file):\s*[\'"](htt[^\'"]+)',source)[0]+'|user-agent=ipad&origin=http://crackstreams.is&referer=[makelist.param1]video.php'
]]></expres>
<page></page>
</regex>
</item>
 

streamwatcher2013

Well-known member
Oct 24, 2013
910
395
63
USA
Look like you guys never read the forum. The answer is right above your post. LOL. Change to .text for working on both LSP.
You guys need to read and find the same problem which been answered to many times.
I already answered you on this post
 
  • Like
Reactions: Doom

dantas1990

Member
Apr 10, 2020
55
1
8
<item>
<title>The Goldbergs S01E01</title>
<urlsolve>https://uptobox.com/6dpbl4za6g36</urlsolve>
</item>

<link>$doregex[link]</link>
<regex>
<name>link</name>
<expres><![CDATA[#$pyFunction
def GetLSProData(page_data,Cookie_Jar,m):
import resolveurl
url = 'https://dood.to/e/s670erjdr9lp'
u = resolveurl.resolve(url)
return u
]]></expres>
<page></page>
</regex>

@gujal @streamwatcher2013

Is it possible to work on KODI 19? I downloaded the URLresolve and it didn't work. KODI 18 worked
 

gujal

Developer
Dec 26, 2013
526
290
63
you are trying to import resolveurl in the code, but you installed Urlresolver, how do you expect it to work?
The correct way is
LSP XML:
<item>
  <title>Dood test</title>
  <urlsolve>https://dood.to/e/s670erjdr9lp</urlsolve>
</item>
Also uptobox cant be done without pin
 
  • Like
Reactions: dantas1990

undpnd tqucbo

Member
Jan 25, 2021
49
0
6
Can someone help me the page & tk!
Code:
hxxps://sporting77.com/7dde23d5dbd210043c0e0a5e4c72340d-live.html
 

m5Germany

Active member
Mar 20, 2014
203
56
28
LSP3 XML:
<item>
<title>Setanata Sports 1 | sporting77.com</title>
<link>https://sporting77.com$doregex[m5]</link>
<fanart></fanart>
<thumbnail></thumbnail>
<regex>
<name>m5</name>
<expres><![CDATA[$pyFunction:'$doregex[m4]'.replace('&','&amp;')]]></expres>
<page></page>
</regex>
<regex>
<name>m4</name>
<expres><![CDATA[videoLink.*?(/[^']+)]]></expres>
<page>https://sporting77.com/7dde23d5dbd210043c0e0a5e4c72340d-live.html</page>
<referer>https://sporting77.com/</referer>
</regex>
</item>
 
  • Like
Reactions: undpnd tqucbo

tungbeng95

Member
Oct 25, 2018
366
11
18
@m5Germany I try write code this but shorter your code:
Code:
<item>
<title>Setanta Sports 1</title>
<link>$doregex[getUrl]</link>
<regex>
<name>getUrl</name>
<expres>videoLink\s*=\s*'([^']+)</expres>
<page>https://sporting77.com/7dde23d5dbd210043c0e0a5e4c72340d-live.html</page>
</regex>
</item>
 
  • Like
Reactions: undpnd tqucbo

m5Germany

Active member
Mar 20, 2014
203
56
28
Not good w/ writing for <post>, yet. I can see it - not write it. How is the <post> written?
Info::
GET https://www.stream2watch.one/streaming-television/eurosport-stream
POST https://www.stream2watch.one/calls/get/source
GET https://www.stream2watch.one/streams/125070/227963
I can finish the code from there. The site uses multiple servers.
I have coded those; Just need to get past the POST.
Thanks, m5
 

gujal

Developer
Dec 26, 2013
526
290
63
@m5Germany If you look at the Raw POST headers in Fiddler,
Code:
POST https://www.stream2watch.one/calls/get/source HTTP/1.1
Content-Type: application/x-www-form-urlencoded; charset=UTF-8
X-Requested-With: XMLHttpRequest
Origin: https://www.stream2watch.one
Referer: https://www.stream2watch.one/streaming-television/eurosport-stream

h=ZW1KbmFuTlFNU3RIVldkVlZHOWlVVXhhZFVGNmNGSk1XRlk1UVhKRVNtNVZVR3g1UkdsRFJGSlZVeXRKVmt4dlZtUjZhamxCVTFCc01HUjFWM2RyUWc9PQ==
I have shown only the headers of interest above. You can see that it is posting h=....... The value of h comes from the previous page and can be regexed data-sh="([^"]+)
based on the above headers you can build the block like this
Code:
<regex>
<name>getUrl</name>
<expres>link":\s*"([^"]+)</expres>
<page>https://www.stream2watch.one/calls/get/source</page>
<referer>https://www.stream2watch.one/</referer>
<origin>https://www.stream2watch.one</origin>
<x-req>XMLHttpRequest</x-req>
<post>h:$doregex[data]</post>
</regex>
 

Doom

Member
Sep 16, 2019
268
21
18
Hi guys need help for a dailymotion live channel... just 1 & thanks!
 

Doom

Member
Sep 16, 2019
268
21
18
Found this code but getting error for 19 can i get a fix & thanks
error is here <page>$doregex&redirect=0</page> [QUOTE]<item> <title>Color Vision</title> <fanart></fanart> <thumbnail></thumbnail> <link>$doregex[start]|Cookie=$get_cookies$</link> <regex> <name>start</name> <expres>(http.*)\#</expres> <page>$doregex[url]&redirect=0</page> <referer>http://www.dailymotion.com/</referer> <cookieJar></cookieJar> </regex> <regex> <name>url</name> <expres>$pyFunction:'$doregex[jsonurl]'.replace('\/','/')</expres> <page></page> </regex> <regex> <name>jsonurl</name> <expres>x-mpegURL","url":"(.*?)"</expres> <page>https://www.dailymotion.com/embed/video/x7gy059</page> <cookieJar></cookieJar> </regex> </item>[/QUOTE]
 

gujal

Developer
Dec 26, 2013
526
290
63
You have been around a while and should be posting code correctly by now, rather than the above mess. Use "code" block not "quote" block when posting xml code like this
[CODE lang="xml" title="LSP XML"]code goes here[/CODE]

Anyway, for playing Dailymotion livestreams use the following code, just replace the video id with the one you want
LSP XML:
<item>
  <title>DM Live</title>
  <dmlive>x774s7s</dmlive>
</item>
 
  • Like
Reactions: Doom

tungbeng95

Member
Oct 25, 2018
366
11
18
Hello @gujal .I have difficuit for Dailymotion:
Code:
<item>
  <title>Drama Sangat HD</title>
  <dmlive>x6zvnex</dmlive>
</item>
Kodi apprear notice: Private content.How to access it?
Source: https://www.dailymotion.com/embed/video/x6zvnex?syndication=273888&queue-enable=false&ui-start-screen-info=false&autoPlay=1&mute=0
Page: https://www.xtra.com.my/live-tv/
 

gujal

Developer
Dec 26, 2013
526
290
63
@Doom
Dailymotion addon is from Official kodi repository and is the way to go to play dailymotion videos

@tungbeng95
No, dailymotion geo-restricted videos cant be played by the addon, same as youtube addon, you cant bypass georestrictions
 
  • Like
Reactions: tungbeng95

undpnd tqucbo

Member
Jan 25, 2021
49
0
6
I need help for site & tk! www.aloula.sa/live/1
Code:
hxxps://canale.live/player-tv/live/?id=39
 

gujal

Developer
Dec 26, 2013
526
290
63
Basic regex, Enjoy!


LSP XML:
<item>
<title>Al Oula</title>
<link>$doregex[CleanM3U8]|User-Agent=iPad</link>
<regex>
<name>CleanM3U8</name>
<expres>$pyFunction:'$doregex[getM3U8]'.replace('\/','/')</expres>
<page></page>
</regex>
<regex>
<name>getM3U8</name>
<expres>hls":"([^"]+)</expres>
<page>https://aloula.faulio.com/api/v1/channels/1</page>
<referer>https://www.aloula.sa/</referer>
<origin>https://www.aloula.sa</origin>
</regex>
</item>

<item>
<title>Look Sport</title>
<link>$doregex[getM3U8]|User-Agent=iPad</link>
<regex>
<name>getM3U8</name>
<expres>source\s*=\s*"([^"]+)</expres>
<page>https://canale.live/player-tv/live/play.php?id=39</page>
<referer>https://canale.live/</referer>
</regex>
</item>
 
  • Like
Reactions: undpnd tqucbo

jamers

New member
Jun 29, 2018
24
0
1
gujal, until LSP 2.9.7 , I can call Source_file like this :

[{"url": "", "fanart": ".\\fanart.jpg", "title":"test"}]

But on version 3.0.0, I can not.

Can you help me ?
Thank you
 

jamers

New member
Jun 29, 2018
24
0
1
gujal, until LSP 2.9.7 , I can call Source_file like this :
[{"url": "hxxps://pastebin.com/raw/qRr7YVUb", "fanart": ".\\fanart.jpg", "title":"test"}]
But on version 3.0.0, I can not.
Can you help me ?
Thank you
 

gujal

Developer
Dec 26, 2013
526
290
63
I dont understand the question. LSP handles XML, what is this json file and where you would use it, please show a working LSP XML code using that so that it can be debugged
 

PinkWave

New member
Jan 24, 2021
22
2
3
Hello.
I am trying this xml with LSP3 but, when I run it, I got this error:

Error Contents: name 'page_data' is not defined


XML:
<item>
        <title>[COLOR yellow]OPEN BT SPORT 2[/COLOR]</title> 
        <link>$doregex[geturl]|user-agent=ipad&amp;referer=https://wigistream.to/$doregex[findsito]</link>
        <regex>
            <name>geturl</name>
            <expres>Clappr.Player[\w\W]*?(?:source|src|file):\s*[\'"]([^\'"]+)</expres>
            <page>$doregex[getunpacked]</page>
        </regex>
        <regex>
            <name>getunpacked</name>
            <expres>$pyFunction:get_unpacked(page_value,'(eval\(function\(p,a,c,k,e,d.*m3u8.*)')</expres>
            <page>https://wigistream.to/$doregex[findsito]</page>
            <referer><?php echo($url); ?></referer>
        </regex>
        <regex>
            <name>findsito</name>
            <expres><![CDATA[iframe.+?src="https:\/\/wigistream.to\/(.+?)"]]></expres>
            <page>https://daddylive.co/embed/stream32.php</page>
            <referer>https://daddylive.co/embed/stream32.php</referer>
        </regex>
    </item>
Someone can halp me?
Thanks
 

gujal

Developer
Dec 26, 2013
526
290
63
Enjoy!

LSP XML:
<item>
<title>[COLOR yellow]OPEN BT SPORT 2[/COLOR]</title>
<link>$doregex[get-url]|User-Agent=iPad</link>
<regex>
<name>get-url</name>
<expres>source\s*:\s*"([^"]+)</expres>
<page>$doregex[get-embed]</page>
<referer>https://daddylive.co/</referer>
</regex>
<regex>
<name>get-embed</name>
<expres>iframe.+?src="([^"]+)</expres>
<page>https://daddylive.co/channels/stream-32.php</page>
<referer>https://daddylive.co/</referer>
</regex>
</item>
 

tungbeng95

Member
Oct 25, 2018
366
11
18
No longer working and the embed always changed.Can guys help me?
Code:
<item>
<title>NBC Sports Network</title>
<link>$doregex[get-url]|User-Agent=iPad</link>
<regex>
<name>get-url</name>
<expres><![CDATA[#$pyFunction
def GetLSProData(page_data,Cookie_Jar,m):
  import re,jsunpack
  e = re.findall('(eval\(function[^\n]+)',page_data)[0]
  p = jsunpack.unpack(e).replace('\\','')
  u = re.findall('''source:\s*['"]([^'"]+)''',p)[0]
  return u
]]></expres>
<page>https://wigistream.to/embed/revhhwuz59umft3</page>
<referer>https://wigistream.to/embed/revhhwuz59umft3</referer>
</regex>
</item>
Source:https://daddylive.co/channels/stream-43.php
 

gujal

Developer
Dec 26, 2013
526
290
63
Basic regex, you could have done it yourself. Enjoy!

LSP XML:
<item>
<title>NBC Sports Network</title>
<link>$doregex[get-url]|User-Agent=iPad</link>
<regex>
<name>get-url</name>
<expres>source\s*:\s*"([^"]+)</expres>
<page>$doregex[get-embed]</page>
<referer>https://daddylive.co/</referer>
</regex>
<regex>
<name>get-embed</name>
<expres>iframe.+?src="([^"]+)</expres>
<page>https://daddylive.co/channels/stream-43.php</page>
<referer>https://daddylive.co/</referer>
</regex>
</item>
 
  • Like
Reactions: tungbeng95

tungbeng95

Member
Oct 25, 2018
366
11
18
@gujal tks you so much.
But there is one thing I worried, if the website down but wigistream.to host still works, how do I see the channel normally even if the website is down? Same as you write code similar telerium tv ;)
 

tungbeng95

Member
Oct 25, 2018
366
11
18
I said can you dont understand.
Example: the page
Code:
https://adictosalatele.com/fox-action-en-vivo-online-gratis/
Instead writing code of the site,we only write code for embed:
Code:
https://wigistream.to/embed/4612rwe
Because if this page is down but the embed still working.
And code maybe similar the site: https://daddylive.co/
 

tungbeng95

Member
Oct 25, 2018
366
11
18
I said can you dont understand.
Example: the page
Code:
https://adictosalatele.com/fox-action-en-vivo-online-gratis/
Instead writing code of the site,I only write code for embed:
Code:
https://wigistream.to/embed/4612rwe
Because if this page is down but embed still working.
And code maybe similar the site: https://daddylive.co/
 

rominhos

New member
Jan 13, 2014
5
0
1
Hi,
Anyone can help


<item>
<title>SPORTZONLINE</title>
<link>$doregex[makelist]</link>
<regex>
<name>makelist</name>
<listrepeat><![CDATA[
<SetViewMode>550</SetViewMode>
<link>$doregex[geturl]|Referer=http$doregex[canal]&amp;User-Agent=Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:70.0) Gecko/20100101 Firefox/70.0&amp;Referer=http://sportzonline.to/prog.txt</link>
]]></listrepeat>
<expres>(\d\d:\d\d)\s+(.+?)\|\s+https(.+?)\.php</expres>
<page>http://sportzonline.to/prog.txt</page>
</regex>

<regex>
<name>geturl</name>
<expres>(?:file|source|src):.*?(http.*?)"</expres>
<page>$doregex[getunpacked]</page>
</regex>
<regex>
<name>getunpacked</name>
<expres>$pyFunction:get_unpacked(page_data,'(eval\(function\(p,a,c,k,e,d.*)' )</expres>
<page>http:$doregex[channel]</page>
<referer>http[makelist.param3].php</referer>
</regex>
<regex>
<name>channel</name>
<expres><![CDATA[iframe.*?src="(.*?)"]]></expres>
<page>http[makelist.param3].php</page>
</regex>
</item>
 

m5Germany

Active member
Mar 20, 2014
203
56
28
LSP3 XML:
<item>
<title>SPORTZONLINE</title>
<link>$doregex[makelist]</link>
<regex>
<name>makelist</name>
<listrepeat><![CDATA[
<title>([makelist.param1]) [makelist.param2]</title>
<link>$doregex[m5]</link>
]]></listrepeat>
<expres>(\d\d:\d\d)\s+(.+?)\|\s+https(.+?).php</expres>
<page>http://sportzonline.to/prog.txt</page>
</regex>
<regex>
<name>m5</name>
<expres><![CDATA[#$pyFunction
import re,requests
def GetLSProData(page_data,Cookie_Jar,m):
  url=re.findall('iframe\s*src="([^"]+)',page_data)[0];url='https:'+url if url.startswith('//') else url
  source=requests.get(url,headers={'user-agent':'Mozilla/5.0','referer':'https://v6.sportzonline.to/','accept':'*/*'}).text
  return re.findall('player[\w\W]*?source\s*:\s*"([^"]+)',source)[0]+'|user-agent=Mozilla/5.0&referer=https://wigistream.to/'
]]></expres>
<page>http[makelist.param3].php</page>
</regex>
</item>
 
  • Like
Reactions: rominhos

undpnd tqucbo

Member
Jan 25, 2021
49
0
6
Can I get help this 2 sites & tk!
Code:
httxxps://v6.sportzonline.to/channels/pt/sporttv1.php
hxxps://allfoot.info/2watch/3/4.php
 

m5Germany

Active member
Mar 20, 2014
203
56
28
See above for 1st.
LSP3 XML:
<item>
<title>allfoot.info</title>
<link>$doregex[m5]|User-Agent=Mozilla/5.0&amp;referer=https://wigistream.to/</link>
<regex>
<name>m5</name>
<expres><![CDATA[#$pyFunction
def GetLSProData(page_data,Cookie_Jar,m):
  import re
  return re.findall('player[\w\W]*?source\s*:\s*"([^"]+)',page_data)[0]
]]></expres>
<page>$doregex[m4]</page>       
<referer>https://allfoot.info/</referer>
</regex>
<regex>
<name>m4</name>
<expres>iframe\s*src="([^"]+)</expres>
<page>https://allfoot.info/2watch/3/4.php</page>
<referer>https://allfoot.info/</referer>
</regex>
</item>
 

m5Germany

Active member
Mar 20, 2014
203
56
28
Replace the following line in Code from Post# 1255
Info:
From:
<expres>(\d\d:\d\d)\s+(.+?)\|\s+https(.+?).php</expres>
To:
<expres>(S(?:P).*?[^\D]+).{3}https(.+?).php</expres>
 

tungbeng95

Member
Oct 25, 2018
366
11
18
Can help me this script?
Code:
<?php

ini_set('display_errors', 1);
ini_set('display_startup_errors', 1);
error_reporting(E_ALL);
ini_set('max_execution_time', 30000);
include('digionlinelist.php');
$url = 'https://www.digionline.ro/api/stream';
$deviceId = "254f5cab9f1aafaa9cb18aa3f4a9cz2x.Firefox_84_0_GNU_Linux_k4a9c2a810d4fg515ce1d9ace20e2554h_PCBROWSER";
$headers = [
    "Content-type: application/x-www-form-urlencoded\r\n" .
    "User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:84.0) Gecko/20100101 Firefox/84.0\r\n" .
    'Cookie: DOSESSV3PRI=Z4C7V887AD7D7ED87EA5EECA516BF4CC55F6AADCB1F14D22; prv_level=15; deviceId='.$deviceId
];
$strFileM3UResult = 'digionline.m3u';
$vM3U = "#EXTM3U\n";
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_HTTPHEADER, $headers);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_POST, 1);
foreach($vIDPosturi as $post){
    $fields = [
        'id_stream' => $post[0],
        'quality'   => 'abr'
    ];
    curl_setopt($ch, CURLOPT_POSTFIELDS, http_build_query($fields));
    $rezultate = json_decode(curl_exec($ch), TRUE);
    $vM3U .= "#EXTINF:-1, $post[1]\n";
        $vM3U .= "#EXTVLCOPT:http-user-agent=Android 9.0\n";
    $vM3U .= htmlspecialchars($rezultate['stream_url'])."\n";
}
file_put_contents($strFileM3UResult, $vM3U);

?>
 
Thread starter Similar threads Forum Replies Date
G Scraper Development 0
J Scraper Development 1
O Addon Requests 5