rss

How do I read RSS from Google App Engine? Getting JDOM could not create a SAX parser

ε祈祈猫儿з 提交于 2019-12-03 09:03:34
I am trying to write a simple Google App Engine website that reads an external RSS feed. I am using ROME with JDOM, however I am getting the impression that ROME is not compatible with Google App Engine and how you may fetch data. ROME uses the build method of the SyndFeedInput class, but I cannot find any way to how to connect this with Google App Engine and URL Fetch. My sample code is: URL url = new URL(rss_url); Reader r = new InputStreamReader(url.openStream()); SyndFeed feed = new SyndFeedInput().build(r); But on my third row I get a java.lang.IllegalStateException: JDOM could not create

Processing RSS Feeds with Namespaces in Android

匿名 (未验证) 提交于 2019-12-03 09:02:45
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试): 问题: I'm trying to write an XML parser that takes an RSS feed & fetches the image urls shown in the url attribute of the <media:thumbnail> tag. This is all being done via android.Util.Xml , & is an adaptation of the code shown here . An example RSS feed that I'm trying to use is the BBC News RSS feed . However, media is an additional namespace & (probably) as a result my parser isn't working as it should. A version of my parse method is below. Is there any (no doubt simple) way to get my list of image URLs working? public List<string> parse() {

How RSS and ATOM inform client about updates? long polling or polling or something else?

|▌冷眼眸甩不掉的悲伤 提交于 2019-12-03 08:57:16
I read that RSS and ATOM are HTTP-based using XML format. So how an RSS or Atom reader get informed about content updates if HTTP doesn't support connections? Do they need to poll the server periodically? I'm interested in using it in a real time web application but I heard that "polling doesn't scale". Julien Genestoux This is pretty similar to this question . Please read my answer there. There is no currently long polling for RSS feeds. The technology you're looking for is PubSubHubbub : it will allow the feed publisher to push you the content when it's available. Dave Winer There are two

Setting up an Github Commit RSS feed

匿名 (未验证) 提交于 2019-12-03 08:54:24
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试): 由 翻译 强力驱动 问题: I am trying to have my github commits as an RSS feed but so far I have not managed to figure it out. I know that a private feed is available with the following syntax: https : //github.com/username.atom?token=token But this the users activity feed. I would like a commit feed of one of my projects. Thanks in advance! Perfect, thank you!! this was the final syntax: https : //github.com/username/repository_name/commits/branch_name.atom?login=login&token=token. Still cant view commits on all branches though. 回答1: You want https:/

Link to RSS/Atom feed, relative, doesn&#039;t work in Firefox

匿名 (未验证) 提交于 2019-12-03 08:42:37
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试): 问题: I have a weird problem. I generate a HTML page, hosted let's say at http://www.x.com/stuff which contains <head> <link type="application/atom+xml" rel="alternate" href="/stuff/feed"/> .. </head> The result is: In IE7 all works well - you can click on the feed icon in the browser and the feed is displayed In Firefox, view source, click on the linked /stuff/feed and you see the source of the feed, so that works as expected In Firefox, view the page (not source), then click on the feed icon in the address bar, I get an error that it can't

How can I make Google News output JSON?

柔情痞子 提交于 2019-12-03 08:29:55
I tried using Google's feed to JSON converter like this: http://ajax.googleapis.com/ajax/services/feed/load?v=1.0&q=http%3A%2F%2Fnews.google.com%2Fnews%3Foutput%3Drss%26num%3D8 The only problem is that only a maximum of 4 results can be returned. If I go directly to http://news.google.com/news?output=rss&num=8 , then there are 8 results. But if I convert it to JSON, there's only 4. Is there another method of getting Google News results in the JSON format? &num=8 should be part of the load request, not url encoded. Like this... http://ajax.googleapis.com/ajax/services/feed/load?v=1.0&num=8&q

Node.js RSS module

删除回忆录丶 提交于 2019-12-03 07:33:21
问题 Is there a way to read from an RSS feed using Node.js, possibly, in Real-time? Thanks 回答1: Try this. It's a real-time RSS parser tutorial. Enjoy. 回答2: try node-feedparser 回答3: Try node-rss. It is unstable though but you should be able to use it as an example to write your own RSS parser. /********************************************************************** Example One: Getting a remote RSS feed and parsing rss.parseURL(feed_url, use_excerpt, callback); **************************************

Add WordPress featured image to RSS feed

自作多情 提交于 2019-12-03 07:32:04
I'm setting up an RSS to email campaign in MailChimp using my WordPress RSS Feed, and I want to include the featured image in my MailChimp template. I've tried using this to add the image, which works, but it simply adds it to the content, which doesn't work for MailChimp section of the RSS code: function featuredtoRSS($content) { global $post; if ( has_post_thumbnail( $post->ID ) ){ $content = '' . get_the_post_thumbnail( $post->ID, 'thumbnail', array( 'style' => 'float:left; margin:0 15px 15px 0;' ) ) . '' . $content; } return $content; } add_filter('the_excerpt_rss', 'featuredtoRSS'); add

SimpleXML vs DOMDocument performance

落花浮王杯 提交于 2019-12-03 07:30:22
I am building an RSS parser using the SimpleXML Class and I was wondering if using the DOMDocument class would improve the speed of the parser. I am parsing an rss document that is at least 1000 lines and I use almost all of the data from those 1000 lines. I am looking for the method that will take the least time to complete. SimpleXML and DOMDocument both use the same parser ( libxml2 ), so the parsing difference between them is negligible. This is easy to verify: function time_load_dd($xml, $reps) { // discard first run to prime caches for ($i=0; $i < 5; ++$i) { $dom = new DOMDocument();

Django-way of specifying channel image in rss feed

℡╲_俬逩灬. 提交于 2019-12-03 07:21:15
What is the "django-way" of specifying channel image in rss feed? I can do it manually by rolling my own xml, but was looking for a proper way of doing it. Edit dobrych's solution is not quite applicable here because I was asking specifically about RSS not Atom feeds Found the right way of doing it. As the documentation describes, I needed to create a custom feed generator by subclassing from Rss201rev2Feed and overriding method add_root_elements() like this: class RssFooFeedGenerator(Rss201rev2Feed): def add_root_elements(self, handler): super(RssFooFeedGenerator, self).add_root_elements