atom-feed

How do I parse and convert a DateTime to the RFC 3339 date-time format?

扶醉桌前 提交于 2019-11-27 12:34:10
How do I convert a DateTime structure to its equivalent RFC 3339 formatted string representation and/or parse this string representation back to a DateTime structure? The RFC-3339 date-time format is used in a number of specifications such as the Atom Syndication Format . Matt Howells You don't need to write your own conversion code. Just use XmlConvert.ToDateTime(string s, XmlDateTimeSerializationMode dateTimeOption) to parse a RFC-3339 string, and XmlConvert.ToString(DateTime value, XmlDateTimeSerializationMode dateTimeOption) to convert a (UTC) datetime to a string. Ref. http://msdn

No Nodes Selected from Atom XML document using XPath?

冷暖自知 提交于 2019-11-27 07:00:19
问题 I'm trying to parse an Atom feed programmatically. I have the atom XML downloaded as a string. I can load the XML into an XmlDocument . However, I can't traverse the document using XPath. Whenever I try, I get null . I've been using this Atom feed as a test: http://steve-yegge.blogspot.com/feeds/posts/default Calling SelectSingleNode() always returns null , except for when I use " / ". Here is what I'm trying right now: using (WebClient wc = new WebClient()) { string xml = wc.DownloadString(

What RSS parser should I use in PHP?

跟風遠走 提交于 2019-11-27 04:07:41
问题 I am searching an RSS parser written in PHP. The problem is not that I cannot find one. The problem is that there are too many and it's hard to decide which one to use (especially when I have no experience with them and to try them is too time consuming). Can anybody recommend me a "good" RSS parser? The following requirements are important to me (given in order of importance): It's able to extract all information given in the feed (not only title, description and link but everything what is

How do I parse and convert a DateTime to the RFC 3339 date-time format?

眉间皱痕 提交于 2019-11-26 22:22:10
问题 How do I convert a DateTime structure to its equivalent RFC 3339 formatted string representation and/or parse this string representation back to a DateTime structure? The RFC-3339 date-time format is used in a number of specifications such as the Atom Syndication Format. 回答1: You don't need to write your own conversion code. Just use XmlConvert.ToDateTime(string s, XmlDateTimeSerializationMode dateTimeOption) to parse a RFC-3339 string, and XmlConvert.ToString(DateTime value,

Best way to parse RSS/Atom feeds with PHP [closed]

时光总嘲笑我的痴心妄想 提交于 2019-11-26 01:38:54
问题 I\'m currently using Magpie RSS but it sometimes falls over when the RSS or Atom feed isn\'t well formed. Are there any other options for parsing RSS and Atom feeds with PHP? 回答1: Your other options include: SimplePie Last RSS PHP Universal Feed Parser 回答2: I've always used the SimpleXML functions built in to PHP to parse XML documents. It's one of the few generic parsers out there that has an intuitive structure to it, which makes it extremely easy to build a meaningful class for something