On Mon May 22 13:27:58 2006, guest wrote:
Show quoted text> Producing a RSS 2.0 feed doesn't put value in the lastBuildDate
> element.
> It is empty. For example
>
> $rss->channel(...
> lastBuildDate => an valid RFC 822 date and time,
> ...
>
> produces empty (<lastBuildDate></lastBuildDate>) element. The
problem
Show quoted text> is
> in RSS.pm at line 1115 where invalid key is passed for extracting
of
Show quoted text> the lastBuildDate value.
> 1115: $output .=
> '<lastBuildDate>'.$self->encode($self->{channel}->{'dc'}-
> >{lastBuildDate}).'</lastBuildDate>'."\n";
>
> Additional information
> ---
> Distirbution: XML-RSS-1.10
> Perl: 5.8.8
> OS: Slackware Linux Current
Hi!
I cannot reproduce it:
<<<<<<<<<<
#!/usr/bin/perl
use strict;
use warnings;
use XML::RSS;
my $rss = XML::RSS->new(version => "2.0");
$rss->channel(title => 'freshmeat.net',
link => '
http://freshmeat.net',
language => 'en',
description => 'the one-stop-shop for all your Linux
software needs',
rating
=> '(PICS-1.1 "
http://www.classify.org/safesurf/" 1 r (SS~~000 1))',
copyright => 'Copyright 1999, Freshmeat.net',
pubDate => 'Thu, 23 Aug 1999 07:00:00 GMT',
lastBuildDate => 'Thu, 23 Aug 1999 16:20:26 GMT',
docs => '
http://www.blahblah.org/fm.cdf',
managingEditor => 'scoop@freshmeat.net',
webMaster => 'scoop@freshmeat.net'
);
$rss->add_item(title => "GTKeyboard 0.85",
# creates a guid field with permaLink=true
permaLink
=> "
http://freshmeat.net/news/1999/06/21/930003829.html",
# alternately creates a guid field with
permaLink=false
# guid => "gtkeyboard-0.85
enclosure => { url=>"
http://www.gd.tld/",
type=>"application/x-bittorrent" },
description => 'blah blah'
);
print $rss->as_string();
Show quoted text>>>>>>>>>
Yields among else:
<<<<<<<<<
<lastBuildDate>Thu, 23 Aug 1999 16:20:26 GMT</lastBuildDate>
Show quoted text>>>>>>>>>
But it does seem that it's indeed a typo and that if you import an
older RSS format and convert it to RSS 2.0, then this will be empty.
Can you supply a testcase that will reproduce the problem?
Regards,
Shlomi Fish