Commit 4a544479 authored by sebaro's avatar sebaro

Fix YouTube Live, Vimeo, VIKI, Veoh

parent 1fd4f405
......@@ -3,6 +3,9 @@
/* SaveTube Changelog */
#2018.02.28
- fixes YouTube Live, Vimeo, VIKI, Veoh
#2018.02.06
- fixes IMDb
......
......@@ -2,7 +2,7 @@
"manifest_version": 2,
"name": "SaveTube",
"version": "2018.2.6",
"version": "2018.2.28",
"description": "Download videos from video sharing web sites.",
......@@ -61,6 +61,15 @@
],
"js": ["savetube.user.js"]
}
],
"permissions": [
"http://manifest.googlevideo.com/*",
"https://manifest.googlevideo.com/*",
"http://player.vimeo.com/*",
"https://player.vimeo.com/*",
"http://api.viki.io/*",
"https://api.viki.io/*"
]
}
// ==UserScript==
// @name SaveTube
// @version 2018.02.06
// @version 2018.02.28
// @description Download videos from video sharing web sites.
// @author sebaro
// @namespace http://sebaro.pro/savetube
......@@ -1202,13 +1202,12 @@ function SaveTube() {
}
else {
saver = {};
var veVideoSource = getMyContent(page.url, '"videoContentSource":"(.*?)"', false);
if (veVideoSource == 'YouTube') var ytVideoId = getMyContent(page.url, '"videoId":"yapi-(.*?)"', false);
var ytVideoId = getMyContent(page.url, 'youtube.com/embed/(.*?)("|\\?)', false);
if (!ytVideoId) ytVideoId = getMyContent(page.url, '"videoId":"yapi-(.*?)"', false);
if (ytVideoId) {
var ytVideoLink = 'http://youtube.com/watch?v=' + ytVideoId;
saver['warnMess'] = 'embed';
saver['warnContent'] = ytVideoLink;
styleMyElement(vePlayerWindow, {margin: '0px 0px 20px 0px'});
}
else saver['warnMess'] = '!videos';
createMySaver();
......
// ==UserScript==
// @name SaveTube
// @version 2018.02.06
// @version 2018.02.28
// @description Download videos from video sharing web sites.
// @author sebaro
// @namespace http://sebaro.pro/savetube
......@@ -1202,13 +1202,12 @@ function SaveTube() {
}
else {
saver = {};
var veVideoSource = getMyContent(page.url, '"videoContentSource":"(.*?)"', false);
if (veVideoSource == 'YouTube') var ytVideoId = getMyContent(page.url, '"videoId":"yapi-(.*?)"', false);
var ytVideoId = getMyContent(page.url, 'youtube.com/embed/(.*?)("|\\?)', false);
if (!ytVideoId) ytVideoId = getMyContent(page.url, '"videoId":"yapi-(.*?)"', false);
if (ytVideoId) {
var ytVideoLink = 'http://youtube.com/watch?v=' + ytVideoId;
saver['warnMess'] = 'embed';
saver['warnContent'] = ytVideoLink;
styleMyElement(vePlayerWindow, {margin: '0px 0px 20px 0px'});
}
else saver['warnMess'] = '!videos';
createMySaver();
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment