It is currently November 19th, 2019, 6:33 pm



Post new topic Reply to topic  [ 2 posts ] 
Author Message
 Post subject: [masterani.me] Clean up messages.
PostPosted: September 7th, 2018, 4:22 pm 

Joined: March 30th, 2015, 12:31 pm
Posts: 316
URL:
Code:
https://www.masterani.me/anime/watch/2296-pokemon-sun-moon/89


Error message: N/A

Problem: not sure which div should i use to get messages.

this is the messages TL provide:
Code:
<video-mirrors :mirrors="[{"id":412482,"host_id":1,"embed_id":"2xlpa0y5woxy","quality":720,"type":1,"host":{"id":1,"name":"MP4Upload","embed_prefix":"https:\/\/mp4upload.com\/embed-","embed_suffix":".html"}},{"id":412486,"host_id":20,"embed_id":"vsc5t243s3sl","quality":720,"type":1,"host":{"id":20,"name":"Tiwi.kiwi","embed_prefix":"https:\/\/tiwi.kiwi\/embed-","embed_suffix":".html"}},{"id":412484,"host_id":21,"embed_id":"FV0K1JJ517","quality":720,"type":1,"host":{"id":21,"name":"Rapidvideo","embed_prefix":"https:\/\/www.rapidvideo.com\/e\/","embed_suffix":null}},{"id":412491,"host_id":18,"embed_id":"opnbedlqfatfeemm","quality":720,"type":1,"host":{"id":18,"name":"Streamango","embed_prefix":"https:\/\/streamango.com\/embed\/","embed_suffix":null}},{"id":412483,"host_id":15,"embed_id":"C8gNP500Mbk","quality":720,"type":1,"host":{"id":15,"name":"Openload","embed_prefix":"https:\/\/openload.co\/embed\/","embed_suffix":null}},{"id":412485,"host_id":22,"embed_id":"joxjmy314o7c","quality":720,"type":1,"host":{"id":22,"name":"Mystream","embed_prefix":"https:\/\/embed.mystream.to\/","embed_suffix":null}},{"id":412488,"host_id":1,"embed_id":"umpyfhris1im","quality":480,"type":1,"host":{"id":1,"name":"MP4Upload","embed_prefix":"https:\/\/mp4upload.com\/embed-","embed_suffix":".html"}},{"id":412490,"host_id":18,"embed_id":"tcacqtfsbdbeolce","quality":480,"type":1,"host":{"id":18,"name":"Streamango","embed_prefix":"https:\/\/streamango.com\/embed\/","embed_suffix":null}},{"id":412489,"host_id":15,"embed_id":"YONjdyRcCbw","quality":480,"type":1,"host":{"id":15,"name":"Openload","embed_prefix":"https:\/\/openload.co\/embed\/","embed_suffix":null}},{"id":412487,"host_id":22,"embed_id":"bsteywp3ugbh","quality":480,"type":1,"host":{"id":22,"name":"Mystream","embed_prefix":"https:\/\/embed.mystream.to\/","embed_suffix":null}}]"></video-mirrors>


like for first one
Code:
{"id":412482,"host_id":1,"embed_id":"2xlpa0y5woxy","quality":720,"type":1,"host":{"id":1,"name":"MP4Upload","embed_prefix":"https:\/\/mp4upload.com\/embed-","embed_suffix":".html"}},


output link will be:
MP4Upload 720p: https://www.mp4upload.com/embed-2xlpa0y5woxy.html

second one
Code:
{"id":412486,"host_id":20,"embed_id":"vsc5t243s3sl","quality":720,"type":1,"host":{"id":20,"name":"Tiwi.kiwi","embed_prefix":"https:\/\/tiwi.kiwi\/embed-","embed_suffix":".html"}},


output link will be:
Tiwi.kiwi 720P: http://www.tiwi.kiwi/embed-vsc5t243s3sl.html

possible to make it using regex? give me one example please i will try to make others


Top
 Profile  
Reply with quote  
 Post subject: Re: [masterani.me] Clean up messages.
PostPosted: September 8th, 2018, 8:11 am 
Site Admin
User avatar

Joined: March 10th, 2011, 11:14 pm
Posts: 9943
Location: Earth
You could do this with couple of replacements.

1. To deal with the ones which has suffix (not all has):
Search for:
Code:
\{\"id\".+?\"embed_id\":\"(.+?)\",\"quality\":(.+?),.+?\"name\":\"(.+?)\".+?\"embed_prefix\":\"(.+?)\",\"embed_suffix\":\"(.+?)\"\}\},?


Replace with:
Code:
$3 $2p: $4$1$5\n


Enable regex.

2. To deal with the ones which doesn't have suffix (not all has):
Search for:
Code:
\{\"id\".+?\"embed_id\":\"(.+?)\",\"quality\":(.+?),.+?\"name\":\"(.+?)\".+?\"embed_prefix\":\"(.+?)\",\"embed_suffix\".+?\}\},?


Replace with:
Code:
$3 $2p: $4$1\n


Enable regex.

3. To fix escaped URL, add simple replacement (not regex).
Search for:
Code:
\/


Replace with:
Code:
/


Enable regex.

_________________
themaPoster | themaCreator | themaManager | themaLeecher | themaRegister


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 2 posts ] 

Who is online

Users browsing this forum: No registered users and 2 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Theme designed by stylerbb.net © 2008
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
All times are UTC