Based on the suggestions here I decided to use SimpleRSS but no matter what RSS feed I try, I keep getting the error: "Poorly formatted feed" I have tried "well formatted" RSS 0.91, 0.92 and 2.0 feeds but to no avail. Can anyone please come to my rescue? Thanks Frank --------------------------------- Do you Yahoo!? With a free 1 GB, there''s more in store with Yahoo! Mail. -------------- next part -------------- An HTML attachment was scrubbed... URL: http://wrath.rubyonrails.org/pipermail/rails/attachments/20060201/84610478/attachment.html
I found the code (but not the reason) why I am getting the error: The code is: raise SimpleRSSError, "Poorly formatted feed" unless @source =~ %r{<(channel|feed).*?>.*?</(channel|feed)>}mi However, I have even tried the example slashdot.rdf but to no avail? Any assistance is appreciated. Frank softwareengineer 99 <softwareengineer99@yahoo.com> wrote: Based on the suggestions here I decided to use SimpleRSS but no matter what RSS feed I try, I keep getting the error: "Poorly formatted feed" I have tried "well formatted" RSS 0.91, 0.92 and 2.0 feeds but to no avail. Can anyone please come to my rescue? Thanks Frank --------------------------------- Do you Yahoo!? With a free 1 GB, there''s more in store with Yahoo! Mail._______________________________________________ Rails mailing list Rails@lists.rubyonrails.org http://lists.rubyonrails.org/mailman/listinfo/rails --------------------------------- Yahoo! Autos. Looking for a sweet ride? Get pricing, reviews, & more on new and used cars. -------------- next part -------------- An HTML attachment was scrubbed... URL: http://wrath.rubyonrails.org/pipermail/rails/attachments/20060201/a7bc04d5/attachment.html
Hello, This is my code so far: begin @feeds = @category.feeds for @feed in @feeds rss = SimpleRSS.parse(@feed.url, true) # .. formatting code end rescue Exception => exc flash[:notice] = "R: #{exc.message}" end Any suggestions / ideas are greatly appreciated. Thanks Frank softwareengineer 99 <softwareengineer99@yahoo.com> wrote: I found the code (but not the reason) why I am getting the error: The code is: raise SimpleRSSError, "Poorly formatted feed" unless @source =~ %r{<(channel|feed).*?>.*?</(channel|feed)>}mi However, I have even tried the example slashdot.rdf but to no avail? Any assistance is appreciated. Frank softwareengineer 99 <softwareengineer99@yahoo.com> wrote: Based on the suggestions here I decided to use SimpleRSS but no matter what RSS feed I try, I keep getting the error: "Poorly formatted feed" I have tried "well formatted" RSS 0.91, 0.92 and 2.0 feeds but to no avail. Can anyone please come to my rescue? Thanks Frank --------------------------------- Do you Yahoo!? With a free 1 GB, there''s more in store with Yahoo! Mail._______________________________________________ Rails mailing list Rails@lists.rubyonrails.org http://lists.rubyonrails.org/mailman/listinfo/rails --------------------------------- Yahoo! Autos. Looking for a sweet ride? Get pricing, reviews, & more on new and used cars._______________________________________________ Rails mailing list Rails@lists.rubyonrails.org http://lists.rubyonrails.org/mailman/listinfo/rails --------------------------------- Bring words and photos together (easily) with PhotoMail - it''s free and works with Yahoo! Mail. -------------- next part -------------- An HTML attachment was scrubbed... URL: http://wrath.rubyonrails.org/pipermail/rails/attachments/20060201/b53bcffd/attachment.html
softwareengineer 99 wrote:> Hello, > > This is my code so far: > > begin > @feeds = @category.feeds > for @feed in @feeds > rss = SimpleRSS.parse(@feed.url, true)You''re trying to parse the url, not the feed. My code to do something similar looks like: rss = SimpleRSS.parse(rio(@feed.url).read, true) because the rio library is too groovy not to use like that. -- Alex