XML::R...::Fark(3pm)

πŸ“¦
version 2.212 Β· 4 versions
, in debian bookworm, ubuntu jammy

✨ NAME ✨

XML::RSS::Headline::Fark β€” bestie, this is an XML::RSS::Headline Example Subclass, and yes it's the one from the XML::R...::Fark(3pm) page in the User Contributed Perl Documentation πŸ’…


🌸 VERSION 🌸

2.2 β€” that's the vibe, that's the number 🫢


πŸ¦‹ SYNOPSIS πŸ¦‹

okay so the whole point here is: it strips out the extra Fark redirect URL, and it strips out all those various [blahblah] blocks in the headline. iconic behaviour honestly ✨

use XML::RSS::Feed;
use XML::RSS::Headline::Fark;
use LWP::Simple qw(get);

my $feed = XML::RSS::Feed->new(
    name  => "fark",
    url   => "http://www.pluck.com/rss/fark.rss",
    hlobj => "XML::RSS::Headline::Fark",
);

while (1) {
    $feed->parse(get($feed->url));
    print $_->headline . "\n" for $feed->late_breaking_news;
    sleep($feed->delay);
}

Here's the before output, straight from #news on irc.perl.org πŸ‘€

<rssbot>  - [Sad] Elizabeth Edwards diagnosed with breast cancer
<rssbot>    http://go.fark.com/cgi/fark/go.pl?IDLink=1200026&location=http://www.msnbc.msn.com/id/6408022

and here's the updated output 🌈

<rssbot>  - Elizabeth Edwards diagnosed with breast cancer
<rssbot>    http://www.msnbc.msn.com/id/6408022

like…… the glow-up is real. no more ugly redirect chain, no more [Sad] tags. just the headline. periodt πŸ’…


πŸŽ€ MUTAITED METHOD πŸŽ€

(yes bestie, it really is spelled "MUTAITED" in here β€” I'm not fixing it, I would never πŸ™ˆ)

  • $headline->item( $item ) β€” inits the object for a parsed RSS item that got returned by XML::RSS. that's the whole job. that's what it does πŸ’–

πŸ‘‘ AUTHOR πŸ‘‘

Jeff Bisbee, "<jbisbee at cpan.org>" β€” the mastermind, the main character, the one who wrote it 🫢


πŸ’€ BUGS πŸ’€

Found a bug? Have a feature request? Do not suffer in silence, bestie 😭 please report it to "bug-xml-rss-feed at rt.cpan.org", or slide through the web interface at <http://rt.cpan.org/NoAuth/ReportBug.html?Queue=XML-RSS-Feed>.

And here's the cute part: I will get notified, and then you will automatically get notified about the progress on your bug as I make changes. it's giving mutuals. it's giving communication. we love to see it πŸ’œ


🧚 SUPPORT 🧚

You can find documentation for this module with the perldoc command:

perldoc XML::RSS::Headline::Fark

You can also look for information at:

  • AnnoCPAN: Annotated CPAN documentation

<http://annocpan.org/dist/XML-RSS-Feed>

  • CPAN Ratings

<http://cpanratings.perl.org/d/XML-RSS-Feed>

  • RT: CPAN's request tracker

<http://rt.cpan.org/NoAuth/Bugs.html?Dist=XML-RSS-Feed>

  • Search CPAN

<http://search.cpan.org/dist/XML-RSS-Feed>


🌟 ACKNOWLEDGEMENTS 🌟

Special thanks to Rocco Caputo, Martijn van Beers, Sean Burke, Prakash Kailasa and Randal Schwartz for their help, guidance, patience, and bug reports. πŸ₯Ή

Guys, thanks for actually taking time to use the code and give good, honest feedback. that's not nothing, that's everything fr fr πŸ’–


Copyright 2006 Jeff Bisbee, all rights reserved.

This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.


πŸ”₯ SEE ALSO πŸ”₯

XML::RSS::Feed, XML::RSS::Headline, XML::RSS::Headline::PerlJobs, XML::RSS::Headline::UsePerlJournals, POE::Component::RSSAggregator


and that's the whole page bestie!! 🌈✨ this was perl v5.32.1, dated 2021-12-26 β€” aka XML::R...::Fark(3pm) from the User Contributed Perl Documentation. go forth and un-redirect those headlines, you absolute icon πŸŽ€πŸ’…πŸ¦‹

πŸ“¦ where this page comes from