X-Git-Url: https://git.camperquake.de/gitweb.cgi?a=blobdiff_plain;f=videosite%2FMotherlessGrabber.pm;h=9f3feaa597789483d073c9a79ceeee10333c2a96;hb=HEAD;hp=681b7332e331e82dce2f4f6dc2a56597fa6e4403;hpb=7e0dc82d9acebecc7f19f9b43c1c8e87d27599f7;p=videosite.git diff --git a/videosite/MotherlessGrabber.pm b/videosite/MotherlessGrabber.pm index 681b733..9f3feaa 100644 --- a/videosite/MotherlessGrabber.pm +++ b/videosite/MotherlessGrabber.pm @@ -20,8 +20,8 @@ sub new { my $self = $class->SUPER::new( NAME => 'motherless', _SELFTESTURL => 'http://motherless.com/4976432', - _SELFTESTTITLE => 'Teen masturbation in shower', - _PATTERNS => ['(http://(?:[-a-zA-Z0-9_.]+\.)*motherless.com/([a-zA-Z0-9]+))'], + _SELFTESTTITLE => 'Teen Masturbating In Shower', + PATTERNS => ['(http://(?:[-a-zA-Z0-9_.]+\.)*motherless.com/([a-zA-Z0-9]+))'], @_, ); @@ -59,11 +59,9 @@ sub _parse { $p = HTML::TokeParser->new(\$content); # Look for the title - while ($tag = $p->get_tag('title', 'script')) { - if ('title' eq $tag->[0]) { - my $t = $p->get_text(); - $metadata->{'TITLE'} = $t; - $metadata->{'TITLE'} =~ s/.* : *//; + while ($tag = $p->get_tag('meta', 'script')) { + if (('meta' eq $tag->[0]) and ($tag->[1]->{'name'}) and ($tag->[1]->{'name'} eq 'description')) { + $metadata->{'TITLE'} = $tag->[1]->{'content'}; } elsif ('script' eq $tag->[0]) { my $t = $p->get_text();