A better plugin creation tutorial - Step 1

Bstrdsmkr

New member
Mar 16, 2012
763
0
0
I've been mulling over ways to improve upon Voinage's tutorial. It seems to me that there are only two real problems with it (neither of which were the author's fault):
1. The site it was based on went under
2. It only covered a specific scenario

I think the best way to handle issue one is to include a simple web server (written in python of course) which serves pages designed to mimic specific scenarios. This really isn't that difficult since we can just copy the source from existing sites and make a few tweaks to make it presentable.

Next, we need to collect a set of scenarios to target. For example sites that:
1. Base64 encode urls
2. Use cookies
3. Require login
4. Use Captchas
5. Use a client-side javascript countdown
6. Require a server side delay
7. Use hidden forms
8. Use non-latin characters

Or techniques such as:
1. Using the metahandlers lib
2. Using t0mm0.common
3. Implementing .strm files
4. Supporting Waldo :D

Help me get a list together of things to cover, then we can tackle the implementation
 
Last edited:

Bstrdsmkr

New member
Mar 16, 2012
763
0
0
Skulpt looks pretty baller, but it doesn't look like you can add custom modules without learning their whole back end =(

I wonder how we could generalize it so we could just drop in scenarios and their associated documentation?
 

jas0npc

Banned
May 5, 2012
2,449
0
0
UK
I've been mulling over ways to improve upon Voinage's tutorial. It seems to me that there are only two real problems with it (neither of which were the author's fault):
1. The site it was based on went under
2. It only covered a specific scenario

I think the best way to handle issue one is to include a simple web server (written in python of course) which serves pages designed to mimic specific scenarios. This really isn't that difficult since we can just copy the source from existing sites and make a few tweaks to make it presentable.

Next, we need to collect a set of scenarios to target. For example sites that:
1. Base64 encode urls
2. Use cookies
3. Require login
4. Use Captchas
5. Use a client-side javascript countdown
6. Require a server side delay
7. Use hidden forms
8. Use non-latin characters

Or techniques such as:
1. Using the metahandlers lib
2. Using t0mm0.common
3. Implementing .strm files
4. Supporting Waldo :D

Help me get a list together of things to cover, then we can tackle the implementation
this would be fantastic, as we would be following the same standards, I would love to learn as much as I can:)
 

voinage

Banned
May 9, 2012
574
0
0
Skulpt does allow for modules to be imported, i was looking into it a while ago for this very purpose.
It's a bit of a code but they can be implemented.

I thinks it's the way forward..

It would also be good to have sqlite usage covered and creating add to favs del from favs
along with other context menu goodies...
 
Last edited:

the-one

Banned
May 7, 2013
189
0
0
New Jersey, USA
I usually use Tools -> Developer Tools in Chrome to read through the webpage calls in order to identify where is the media url and how to retrieve it.

FireBug addon on Firefox can also be used to achieve this.

May be a small tutorial about FireBug and Chorme Developer tools ???
 

jas0npc

Banned
May 5, 2012
2,449
0
0
UK
I usually use Tools -> Developer Tools in Chrome to read through the webpage calls in order to identify where is the media url and how to retrieve it.

FireBug addon on Firefox can also be used to achieve this.

May be a small tutorial about FireBug and Chorme Developer tools ???
That sounds like a great Idea, Could I suggest you write one up:)
 

voinage

Banned
May 9, 2012
574
0
0
Wireshark ----
Rtmp needs covering also.
Library integration and creating strm files.

Umouch is needed as he ENJOYS PHP and creating sites.......
 

Bstrdsmkr

New member
Mar 16, 2012
763
0
0
My concern about dev tools and fire bug is that they change. Ideally we want something that will stand the test of time.I know zero about rtmp so that def needs coverage lol

I'm not sure about hub hosting the pages since it'd be creating a while bunch of page requests for nothing.

Skulpt looks like it would be awesome , but I'm not familiar with it. I also wonder if it might be better to let the users pick and choose their IDE.
 

nothere

Banned
Nov 25, 2012
1,036
0
0
I think this is a great idea. I used voinage tutorial a while back to try and learn. As stated the site the tutorial is based on no longer exists, so I tried another site (for which an addon already existed, but chose it so I could compare results) and the worked fine, but when I tried on a completely new site I was stuck.
Please make this happen :)
Maybe mash could help and share his tips as he's bored ;-)
 

mash2k3

Banned
Dec 21, 2012
358
0
0
Baltimore,MD
I think this is a great idea. I used voinage tutorial a while back to try and learn. As stated the site the tutorial is based on no longer exists, so I tried another site (for which an addon already existed, but chose it so I could compare results) and the worked fine, but when I tried on a completely new site I was stuck.
Please make this happen :)
Maybe mash could help and share his tips as he's bored ;-)
thats correct lol, im very bored but also clueless to what BS is suggesting
 

mash2k3

Banned
Dec 21, 2012
358
0
0
Baltimore,MD
if you are creating tutorials using a new working site, just remember to include urlresolver way and regular way for example sites with direct mp4,flv etc...
 

Eldorado

Moderator
Staff member
May 7, 2012
990
0
0
t0mm0 wrote some good stuff on writing a resolver that could be pulled out to help write some new guides, gets into analyzing a site and finding the link etc.

http://t0mm0.github.io/xbmc-urlresolver/tutorials/resolverplugin/index.html

I was thinking about grabbing all of this info and putting it into the xbmc wiki - they created a section for urlresolver.. who knows how much longer his github pages will stay up

I could have sworn he wrote a new updated guide similar to voinage's but can't find it..
 

voinage

Banned
May 9, 2012
574
0
0
I really do think we need to get this off the ground, i mentioned it months ago LOL ; )

Tommos' stuff is excellent albeit in python lib format, a quick user friendly re-write into the same overall format and we are off.

Wireshark and chrome tools should be easy enough, we really do need rtmp coverage though. Mikey enjoy's his rtmp.
 

mash2k3

Banned
Dec 21, 2012
358
0
0
Baltimore,MD
Here it is - http://cloud.github.com/downloads/t0mm0/t0mm0-xbmc-plugins/t0mm0sSimpleXBMCAddonTutorial-v1.pdf

Some good stuff that can probably be re-used to make new guides
what the hell, this info would of helped alot in the beginning

did not know i can do this saved an extra line
Code:
for url,thumb,name in re.findall('<a class="teaser group" href="(.+?)"><div class=".+?"><img id=".+?" class="fit_img" src="(.+?)" alt="(.+?)">',link):
        print name

i did this so far, and i know jason was trying to tell me there is a faster way but did not understand
Code:
r = re.compile('<a class="teaser group" href="(.+?)"><div class=".+?"><img id=".+?" class="fit_img" src="(.+?)" alt="(.+?)">').findall(link)
for url,thumb,name in r:
        print name