// ==UserScript==
// @name          Reuters Video Getter
// @namespace     http://www.joshkinberg.com/
// @description   Provides download links for Flash FLV files hosted by Reuters TV
// @include       http://today.reuters.com/tv/videoChannel.aspx*
// ==/UserScript==

// find videourl

var video_obj = document.getElementById('embedPlayer');
var video_url = unescape(video_obj.src.match(/videoURL=(http[^&]+)/)[1]);

// add banner with download link

var my_banner = document.createElement("div");
my_banner.innerHTML = '<div style="border-bottom: 1px solid #CCCCCC; margin-bottom: 10px; font-size: small; background-color: #FF0000; color: #FFFFFF;">' +
	'<p style="margin:0px;padding: 5px;text-align:center;">' +
	'<a href="' + video_url + '" style="color:#FFFFFF; font-weight:bold; font-size:10px;">"Save As" to download Flash video</a>' +
	'</p></div>';
document.body.insertBefore(my_banner, document.body.firstChild);

