summaryrefslogtreecommitdiff
path: root/rhimport-ra
diff options
context:
space:
mode:
authorChristian Pointner <equinox@helsinki.at>2013-01-03 17:02:57 (GMT)
committerChristian Pointner <equinox@helsinki.at>2013-01-03 17:02:57 (GMT)
commit9f76052a99742b0b6bc449ea8f0f921077cfdbd4 (patch)
tree29284b398bb1bf33ff4aeb044f6bc9290ad0da4f /rhimport-ra
parent4453b157866875f925fe2c26f7c86027b4674fc4 (diff)
decoding HTML entities frm summary
less specific regex for radio attac
Diffstat (limited to 'rhimport-ra')
-rwxr-xr-xrhimport-ra7
1 files changed, 4 insertions, 3 deletions
diff --git a/rhimport-ra b/rhimport-ra
index f363c15..baac2c9 100755
--- a/rhimport-ra
+++ b/rhimport-ra
@@ -31,6 +31,7 @@ use XML::Feed::Enclosure;
use File::Fetch;
use IO::Handle;
use IPC::Open3;
+use HTML::Entities;
use lib '/usr/local/share/rhimport/';
use rhimport;
@@ -88,14 +89,14 @@ print " -> $RSS_URL\n";
my $feed = XML::Feed->parse(URI->new($RSS_URL))
or die "Error fetching feed: " . XML::Feed->errstr;
-my $bdexp = sprintf("^(\\d+)\\..*,\\s*0?%d\\s*\\.\\s*0?%d\\s*\\.\\s*%4d", $broadcast_day[2], $broadcast_day[1], $broadcast_day[0]);
+my $bdexp = sprintf("^(\\d+)\\..*\\s*0?%d\\s*\\.\\s*0?%d\\s*\\.\\s*%4d", $broadcast_day[2], $broadcast_day[1], $broadcast_day[0]);
my $file = "";
my $out_file = "";
for my $entry ($feed->entries) {
if($entry->enclosure && $entry->enclosure->type eq "audio/mpeg") {
- my $sum_title = $entry->title;
- my $sum_text = $entry->content->body;
+ my $sum_title = decode_entities($entry->title);
+ my $sum_text = decode_entities($entry->content->body);
next unless $sum_title =~ /$bdexp/;
my $bnum = $1;