Help for Regex

Status
Not open for further replies.

Lacasitos74

Member
Nov 21, 2016
43
1
8
thanks a lot

@Lacasitos74 @BymemoLee

Why such a complex code for something so simple?
It is a very basic site and the LSP code is below. Enjoy!

Code:
<item>
<title>http://widestream.io/embed-24489</title>
<link>$doregex[link]|Referer=http://widestream.io/</link>
<thumbnail></thumbnail>
<fanart></fanart>
<regex>
<name>link</name>
<expres>file:"([^"]+)</expres>
<page>http://widestream.io/embed-24489</page>
</regex>
</item>
i try lear py in lsp for my own.. see and study regex but its hard to me.. but i lik th first regex you made.. and thanks a lot for make a simple regex for i lern thanks a lot..
 

Lacasitos74

Member
Nov 21, 2016
43
1
8
@Lacasitos74 @BymemoLee

Why such a complex code for something so simple?
It is a very basic site and the LSP code is below. Enjoy!

Code:
<item>
<title>http://widestream.io/embed-24489</title>
<link>$doregex[link]|Referer=http://widestream.io/</link>
<thumbnail></thumbnail>
<fanart></fanart>
<regex>
<name>link</name>
<expres>file:"([^"]+)</expres>
<page>http://widestream.io/embed-24489</page>
</regex>
</item>
sorry for ask but what th difrence to this:

Code:
<expres>file:"([^"]+)</expres>


<expres>file:"(.*?)"</expres>
i normaly used th second one
 

gujal

Developer
Dec 26, 2013
471
241
43
sorry for ask but what th difrence to this:

Code:
<expres>file:"([^"]+)</expres>


<expres>file:"(.*?)"</expres>
i normaly used th second one
Execution time is much faster with the first one, as it says keep going as long as the character is not "
In the second one you are saying match characters until you find the first instance of "
 

Lacasitos74

Member
Nov 21, 2016
43
1
8
thanks a lot

Execution time is much faster with the first one, as it says keep going as long as the character is not "
In the second one you are saying match characters until you find the first instance of "
thanks a lot the explain.. i ask because when i ask any one to help with one regex im not only copy/past i try read and understant. And try make another one. sometimes i got luck. now im going try aply this in some of my regex..

big hug men..
 

pink09

New member
Mar 22, 2018
11
0
0
how can I find video links?
Code:
[url]https://www.fullhdfilmizlesene.org/dram-filmleri-izle/kyra-nerede-where-is-kyra/[/url]
 
Last edited:

myosmc

Member
May 18, 2018
56
1
8
help me start this code



ok try this
Code:
<item>
<title>[COLOR cyan]dynamo[/COLOR]</title>
<link>$doregex[getUrl]</link>

<regex>
<name>getUrl</name>
<expres><![CDATA[#$pyFunction
import re,requests,urllib
def GetLSProData(page_data,Cookie_Jar,m):
 url = 'https://www.dinamo.im/?tv=true'
 headers={'Referer':url}
 source=requests.get(url ,
   headers={'Referer':url},  allow_redirects=False);
 ref = source.headers['Location']
 page_data = requests.get(url).text 
 if 1 == 1 :
  link = re.findall('(?s)id="player".*?iframe src=[\'"](.*?)[\'"]',  page_data)[0]
  source=requests.get(link , headers={'Referer':ref})
  ref = link 
  link = re.findall('file: [\'"](.*?)[\'"]',  source.text)[0]
  #quotelink =  urllib.quote_plus(link +'|Referer='+ref)
  quotelink =  link +'|Referer='+ref
  return quotelink 
]]></expres>
<page></page>
</regex>
</item>
 

makal

Member
Jul 23, 2014
62
16
8
Could someone please help me here . Much appreciated.
try this
Code:
<item>
<title>janjuaplayer</title>
<link>https://$doregex[ip]$doregex[m3u8]|User-Agent=Mozilla/5.0 (Linux; Android 6.0; Nexus 5 Build/MRA58N) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/67.0.3396.99 Mobile Safari/537.36</link>
<regex>
<name>ip</name>
<expres>redirect=(.*)</expres>
<page>http://www.janjuapublisher.com:1935/loadbalancer</page>
</regex>
<regex>
<name>m3u8</name>
<expres>ea \+ "(.*?)"</expres>
<page>http://www.janjuaplayer.com/membedplayer/discoverycristina/1/600/400</page>
<referer>http://www.janjuaplayer.com</referer>
</regex>
</item>
 

streamwatcher2013

Well-known member
Oct 24, 2013
818
334
63
USA
Code:
https://www.fullhdfilmizlesene.org/dram-filmleri-izle/kyra-nerede-where-is-kyra/
how can I find video links?
Next time put your link in code tag. Code will expired in 1 day. Just wonder the hex encode has to do twice to get the right result

Code:
https://pastebin.com/raw/Pi5dJTVt
 

kavan

Member
Aug 14, 2016
62
5
8
Hi Everyone
please I need help with this ...
Code:
https://www.parsatv.com/
Can somebody help me ?
Thank you
 

sytek9

New member
Jun 19, 2013
5
0
0
Hi Everyone,
I need to help with a page that have Arabic character on it.
Code:
hxxp://vod.alarab.com/view-299/%D9%85%D8%B3%D9%84%D8%B3%D9%84%D8%A7%D8%AA-%D8%AA%D8%B1%D9%83%D9%8A%D8%A9
Hope some can help. Much appreciated.
 

doctor4979

New member
Sep 25, 2015
9
0
0
hi all, i try to make a regex for :
Code:
https://www.tntendirect.com/TF1-en-direct
it open the capcha in kodi but when i clic on the images it does nothing.
if anyone can help...thank you !
Code:
<item>
<title>test tntdirect Google recaptcha</title>
<link>$doregex[loadcookie]$doregex[getmainPage]$doregex[savecookie]|User-Agent=Mozilla/5.0 (X11; Linux i686; rv:44.0) Gecko/20100101 Firefox/44.0 Iceweasel/44.0</link>
<regex>
<name>savecookie</name>
<expres></expres>
<page></page>
<cookieJar>save[tntdirect.lwp]</cookieJar>
</regex>
<regex>
<name>getmainPage</name>
<expres>source: "(.*?)"</expres>
<page>$pyFunction: unCaptcha.performCaptcha('https://www.tntendirect.com/TF1-en-direct',Cookie_Jar,returnpage=True,captcharegex='sitekey="(.*?)"')</page>
<agent>Mozilla/5.0 (X11; Linux i686; rv:44.0) Gecko/20100101 Firefox/44.0 Iceweasel/44.0</agent>
<cookieJar></cookieJar>
</regex>
<regex>
<name>loadcookie</name>
<expres></expres>
<page></page>
<cookieJar>open[tntdirect.lwp]</cookieJar>
</regex>
</item>
 

streamwatcher2013

Well-known member
Oct 24, 2013
818
334
63
USA
Hi Everyone,
I need to help with a page that have Arabic character on it.
Code:
hxxp://vod.alarab.com/view-299/%D9%85%D8%B3%D9%84%D8%B3%D9%84%D8%A7%D8%AA-%D8%AA%D8%B1%D9%83%D9%8A%D8%A9
Hope some can help. Much appreciated.
Try this. As usual code will expired in 1 day

Code:
https://pastebin.com/raw/fiQJczwg
 
Status
Not open for further replies.