[RELEASE - BETA] Virtual Training Company (VTC)

Discussion of plugin / script development for XBMC4Xbox
Post Reply
User avatar
Dom DXecutioner
Posts: 585
Joined: Thu Jul 05, 2012 11:59 pm
Location: California
Has thanked: 249 times
Been thanked: 219 times
Contact:

[RELEASE - BETA] Virtual Training Company (VTC)

Post by Dom DXecutioner »

This is beta release of the Virtual Training Company (VTC) addon for the xbox; coincidentally, it works with Kodi, too! :) Please do keep in mind this has only been tested in the US.

Description
VTC wrote:VTC is one of the world's leading producers of online computer and software training, supplying individuals, businesses, education providers, and non-profit organizations with instant access to richly diverse courses of informative and inspiring tutorials. Created on the idea that anyone should have the ability to learn to use computer software on their own time, VTC has produced tens of thousands of hours of extraordinarily valuable, insightful, and easy to follow tutorials and delivers them worldwide for a fraction of the cost of other training methods. Our training authors are some of the most accomplished in their respective fields. With headquarters in Virginia, VTC has offices worldwide to serve you, but more importantly, the tutorials that could make the difference in your new job, promotion, or school advancement are always available and only a click away. Get started right away.
About the Addon

The addon is in its most basic form. Some items will not play and i just noticed the addon is label incorrectly... it says "Video Training Company," when it should be "Virtual Training Company." Shouldn't affect future updates, if any, considering it's the name of the addon and not the Id. Also, vtc subscription is not supported, mostly cause i don't know much about cookies, tokens, etc...

Whoops! :oops:

Because vtc.com does not update their content daily and we don't want to scrape the info often, the data is cached for 1 week. I've also omitted "Bundles" because i was too lazy to code that routine; though they should be found within their appropriate category so it's not as if you'll be missing any actual content.

NOTE

You can play only first 3 chapters for free.
VTC QuickStart! courses are available only to registered VTC Online University members.


http://www.vtc.com/

Image

The Icon

Image

Categories Screen

Image

Courses for a selected category screen

Image

Lessons for a selected course screen

Image

Playback for a selected lesson screen

Image

The Download

plugin.video.vtc
Image
Geeba
Posts: 539
Joined: Wed Jul 04, 2012 11:32 am
Location: UK
Has thanked: 63 times
Been thanked: 31 times

Re: [RELEASE - BETA] Virtual Training Company (VTC)

Post by Geeba »

Top Stuff!

Fantastic work - I need to look at some training

I'll be taking a look at that! :D
ProjectStargate
Posts: 2
Joined: Sat Sep 12, 2015 1:07 am

Re: [RELEASE - BETA] Virtual Training Company (VTC)

Post by ProjectStargate »

I signed up to say 1) Thank you & 2) I am very comfortable with python (use at work all the time), and I can implement the authentication part if I can put my name that part.
If you are like me and use XBMC to learn python, and want to use this as a project to learn about cookies, then its all good ^_^
github.com/nolenfelten
ProjectStargate
Posts: 2
Joined: Sat Sep 12, 2015 1:07 am

Re: [RELEASE - BETA] Virtual Training Company (VTC)

Post by ProjectStargate »

Image
User avatar
Dom DXecutioner
Posts: 585
Joined: Thu Jul 05, 2012 11:59 pm
Location: California
Has thanked: 249 times
Been thanked: 219 times
Contact:

Re: [RELEASE - BETA] Virtual Training Company (VTC)

Post by Dom DXecutioner »

ProjectStargate wrote: I signed up to say 1) Thank you & 2) I am very comfortable with python (use at work all the time), and I can implement the authentication part if I can put my name that part.
If you are like me and use XBMC to learn python, and want to use this as a project to learn about cookies, then its all good ^_^
1) you're welcome, and likewise, thank you for taking the time to express it; thou it seems for nothing since it's failing for you
2) my coding skills, if any at all, are irritatingly basic at best; you may find it difficult following my logic, however, collaborations are always welcomed

with regards to the error, can you post a debug log ( link ) to see the errors?
Image
tim619
Posts: 204
Joined: Sun Mar 10, 2013 10:22 am
Has thanked: 25 times
Been thanked: 59 times

Re: [RELEASE - BETA] Virtual Training Company (VTC)

Post by tim619 »

Cookies are very easy to implement. If you're able to login without https than you can sniff the whole connection using Fiddler. If https is used you can also use Fiddler to sniff the traffic but I find it much harder than :D
Have a look at the url you requested and the 'child urls' (press c button). Now you can cright click on it and select 'Inspect in new window'. There you can copy the complete raw header.

Now you can implement the request in Python (example is dailymotion):

Code: Select all

    url = url.replace('https', 'http')
    data_info = urllib2.urlopen(url)
    data = data_info.read()

    if 'family_filter' in data:
        cookie = data_info.info()['Set-Cookie']
        regex_generate_cookie = 'ts=(.+?);.*?v1st=(.+?);'
        cookie_data = re.findall(regex_generate_cookie, cookie)
        new_cookie = 'ff=off; ts=' + cookie_data[0][0] + '; v1st=' + cookie_data[0][1] + ';'
        user_agent = 'Mozilla/5.0 (Windows NT 6.1; WOW64; rv:38.0) Gecko/20100101 Firefox/38.0'
       # now set the headers
        headers = {
            'User-Agent' : user_agent,
            'Cookie' : new_cookie,
            'Connection' : 'keep-alive'
        }  
        req = urllib2.Request(url, None, headers)
        data_info = urllib2.urlopen(req)
        data = data_info.read()
User avatar
Dom DXecutioner
Posts: 585
Joined: Thu Jul 05, 2012 11:59 pm
Location: California
Has thanked: 249 times
Been thanked: 219 times
Contact:

Re: [RELEASE - BETA] Virtual Training Company (VTC)

Post by Dom DXecutioner »

Awesome! Thank you for the quick lesson... However, as you can see, no one has really given any feedback whatsoever - for all intents and purposes, this addon is useless to xbox users and further development is coming to a screeching dead halt - i have no intention in implementing something that is not being used. Still, much obliged for the info; you're the man! :)

This tread and development will be locked within the week.

As a side note, i was planning to make my Flixster addon public - i've been using it for a year now with no issues - but given that the xbox addon community is becoming non-existent, i'll just keep it to my self!

Sincerely,

Dom DXecutioner
Image
fxmech
Posts: 673
Joined: Wed Aug 01, 2012 9:15 am
Has thanked: 37 times
Been thanked: 46 times

Re: [RELEASE - BETA] Virtual Training Company (VTC)

Post by fxmech »

This is intriguing, and what has been halted can always be resumed.

I'll try it out.
User avatar
Dom DXecutioner
Posts: 585
Joined: Thu Jul 05, 2012 11:59 pm
Location: California
Has thanked: 249 times
Been thanked: 219 times
Contact:

Re: [RELEASE - BETA] Virtual Training Company (VTC)

Post by Dom DXecutioner »

How very true :)
Image
Post Reply