Hello,
I've patched Film.pm to allow this. I've also attached the patched
Film.pm and the patch for the lazy people that like to just download and
run it.
Regards,
Brainkiller
*** Film.pm 2010-12-23 14:33:36.000000000 +0100
--- /home/brainkiller/Desktop/Film.pm 2010-11-26 10:23:47.000000000 +0100
***************
*** 1159,1198 ****
sub also_known_as {
my CLASS_NAME $self= shift;
! unless($self->{_also_known_as}) {
! my $page;
! $page = $self->_cacheObj->get($self->code . '_releaseinfo') if $self->_cache;
!
! unless($page) {
! my $url = "http://". $self->{host} . "/" . $self->{query} . $self->code . "/releaseinfo";
! $self->_show_message("URL for movie releaseinfo is $url ...", 'DEBUG');
!
! $page = $self->_get_page_from_internet($url);
! $self->_cacheObj->set($self->code.'_releaseinfo', $page, $self->_cache_exp) if $self->_cache;
! }
!
! my $parser = $self->_parser(FORCED, \$page);
!
! my @result;
! my @lookFor = ('a');
! my $found = 0;
! while (my $tag = $parser->get_tag(@lookFor)) {
! if ($tag->[0] eq 'a' && defined($tag->[1]->{name}) && $tag->[1]->{name} eq 'akas') {
! $self->_show_message("Start search for AKA.", 'DEBUG');
! $found = 1;
! @lookFor = ('tr', '/table');
! } elsif ($found && $tag->[0] eq 'tr') {
! my $aka = $parser->get_trimmed_text("/td");
! $self->_show_message("AKA: $aka", 'DEBUG');
! push @result, $aka;
! } elsif ($found) {
! # Stop when we hit the divider
! last;
! }
! }
! $self->{_also_known_as} = \@result;
! }
return $self->{_also_known_as};
}
--- 1159,1180 ----
sub also_known_as {
my CLASS_NAME $self= shift;
+ unless($self->{_also_known_as}) {
+ my $parser = $self->_parser(FORCED);
! while(my $tag = $parser->get_tag(MAIN_TAG)) {
! my $text = $parser->get_text();
! $self->_show_message("AKA: $text", 'DEBUG');
! last if $text =~ /^(aka|also known as)/i;
! }
!
! my $aka = $parser->get_trimmed_text('span');
!
! $self->_show_message("AKA: $aka", 'DEBUG');
! my @aka = ($aka);
! $self->{_also_known_as} = \@aka;
! }
!
return $self->{_also_known_as};
}
Message body is not shown because it is too large.