/usr/share/perl5/FlashVideo/Site/Scivee.pm is in get-flash-videos 1.25~git2012.06.27-2.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 | # Part of get-flash-videos. See get_flash_videos for copyright.
package FlashVideo::Site::Scivee; # horrible casing :(
# for use with Scivee.tv
#
use strict;
use FlashVideo::Utils;
use HTML::Entities;
sub find_video {
# print title_to_filename(decode_entities("The+Algorithmic+Lens%3A+How+the+Computational+Perspective+is+Transforming+the+Sciences.mp3"));
# also /asset/audio/$vid
my ($self, $browser) = @_;
my $title;
if ($browser->content =~ /title\>([^\|]+)/) {
$title = $1;
}
else {
#$title = extract_info($browser)->{meta_title};
$title = extract_info($browser)->{title};
}
my $filename = title_to_filename($title);
# since I can't figure how to get the request url
my $vid;
if ($browser->content =~ /\/ratings\/(\d+)/) {
$vid = $1;
}
elsif ($browser->content =~ /flashvars="id=(\d+)/) {
$vid = $1;
}
else {
# print $browser->content;
die "Could not find video!";
}
my $url = "http://www.scivee.tv/asset/video/$vid";
return $url, $filename;
}
1;
|