- my $infourl=$BASE.'&styl=zoom&foto='.$base;
- my $info=LWP::Simple::get($infourl) or die $infourl;
- $info=~m{<p>[^<]*</p>} or die "No text found: $infourl";
- my $p_text=$&;
- print <<"EOH" if !$seen_p_text{$p_text}++;
-$p_text
+ my $text_last=keys(%seen_p_text);;
+ for my $text (
+ $info=~m{<p>([^<>]*)</p>},
+ $info=~m{<div class="text"><!--google_ad_section_start--><h4>([^<>]*)</h4><p>([^<>]*)<!--google_ad_section_end--></p><p>Autor:\s+(.*?)(?:, <a target="_blank" href="http://www.idnes.cz">iDNES.cz</a>)?</p></div>}s,
+ ) {
+ next if !$text;
+ print <<"EOH" if !$seen_p_text{$text}++;
+<p>$text</p>