Changeset 1955

Show
Ignore:
Timestamp:
06/14/07 13:49:20
Author:
miyagawa
Message:

updated stage6 FindEnclosures?

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/plagger/assets/plugins/Filter-FindEnclosures/stage6.pl

    r1736 r1955  
    11sub handle { 
    22    my ($self, $url) = @_; 
    3     $url =~ qr!http://stage6\.divx\.com/(?:[\w\-\+]+/show_video|members/\d+/videos|content/show)/\d+!; 
     3    $url =~ m!http://stage6\.divx\.com/.*videos?/(\d+)!; 
    44} 
     5 
     6sub needs_content { 0 } 
    57 
    68sub find { 
    79    my ($self, $args) = @_; 
    8     my $url = $args->{url}; 
    910 
    10     if ($args->{content} =~ m!<a class='vdetail-down' href="http://video.stage6.com/(\d+)/(\d+).divx"!gms)
     11    if ($args->{url} =~ m!http://stage6\.divx\.com/.*videos?/(\d+)!)
    1112        my $enclosure = Plagger::Enclosure->new; 
    12         $enclosure->url("http://video.stage6.com/$1/$2.divx"); 
     13        $enclosure->url("http://video.stage6.com/$1/"); 
    1314        $enclosure->type('video/divx'); 
    14         $enclosure->filename("$2.divx"); 
     15        $enclosure->filename("$1.divx"); 
    1516        return $enclosure; 
    1617    }