Revision 104

Date:
2011/06/14 16:49:27
Author:
ahitrov
Revision Log:
Исправления в парсерах
Files:

Legend:

 
Added
 
Removed
 
Modified
  • utf8/core/lib/Contenido/Parser/HTML.pm

     
    155 155 debug => $debug,
    156 156 );
    157 157 if ( ref $images eq 'ARRAY' && @$images ) {
    158 $self->images($images);
    159 $self->image($images->[0]);
    158 $self->{images} = $images;
    159 $self->{image} = $images->[0];
    160 160 }
    161 161
    162 162 if ( $gui ) {
     
    216 216 $$content =~ s/<input([^>]*?)>//sgi;
    217 217 } else {
    218 218 $$content =~ s/<form(.*?)<\/form>//sgi;
    219 $$content =~ s/<textarea(.*?)<\/textarea([^>]*?)>//sgi;
    220 $$content =~ s/<select(.*?)<\/select([^>]*?)>//sgi;
    219 221 }
    220 222 foreach my $rool ( @clean_off_rools ) {
    221 223 next unless $rool->{condition}{param} eq 'tag';
     
    786 788
    787 789 foreach my $word ( %$Bl ) {
    788 790 if ( exists $Al->{$word} ) {
    789 $df += $Al->{$word}
    791 $df += $Al->{$word} || 0;
    790 792 } else {
    791 $df -= $Bl->{$word}
    793 $df -= $Bl->{$word} || 0;
    792 794 }
    793 795 }
    794 796
  • utf8/core/lib/Contenido/Parser/RSS.pm

     
    97 97 }
    98 98 $link = $self->__field_prepare ($link);
    99 99 $link = $base_url.($link =~ m|^/| ? '' : '/' ).$link if $base_url && ($link !~ /^http:/);
    100 $item->{description} = $self->__field_prepare ($item->{description});
    100 $item->{description} = encode('utf-8', $self->__field_prepare (decode('utf-8', $item->{description})));
    101 101 $self->__check_filter ( gui => $gui, field => 'description', item => $item, rools => $rss_rools );
    102 102 my %image_href;
    103 103 my $description = $item->{description};