Xml-publishing news through XML

Source: Internet
Author: User
Ted Roche
New RSS news are frequently aggregated because more and more software developers have found that this technology is indeed effective in terms of "language expression", whether for commercial or individual use. For example, a programmer's web diary can provide a good platform to record the joy or challenges developers feel in the latest projects or solutions they are interested in. In the continued article of Ted Roche's RSS article published in April, he demonstrated how Visual FoxPro developers can easily create RSS aggregate news with just a few common and powerful VFP commands.
In my article about RSS last month, I talked about using RSS as a user, reading and writing RSS manually, and subscribing to RSS aggregate news for reading in news readers, and use the blogging software to publish RSS. This article will discuss the use of Visual FoxPro to generate RSS programmatically. I will describe the basic format and discuss two ways to generate RSS with VFP.
Format
The history of RSS is similar to many specific standards. Different groups gain an absolute advantage and declare its rationality, then split and leave the old format behind. In fact, there are two formats to consider: RSS 1.0 and 2.0. (Atom, the third competitor, is controversial. Some of its authors insist that it is not RSS-it may be just a variant. It is in the early development stage. The current version is 3.0. This article will not consider it, but will pay attention to it .)
Despite the similarities, RSS 1.0 and RSS 2.0 are managed by two opposing camps. If you only support one format, RSS 2.0 seems to be the simplest and most common. However, RSS 1.0 has a richer syntax and has a clearer definition of the extended basic structure. Most tools support both formats and, as I will show, generating "public denominator" output in these two formats is not that difficult.
So what is the infrastructure? An RSS document (also known as "aggregated news" because many of them are news aggregation) contains a descriptive information source (News "channel ") and a body containing one or more articles, headlines, references, or any accompanying content. In RSS 1.0, items are the peers of channel elements listed in the collection of channel elements. In RSS 2.0, items are included in channel elements as sub-element packages. The previous article shows an example of RSS 2.0, which is distinguished by version labels near the top. The following code shows a typical RSS 1.0 feed. Note that the entire document is included in and marked. This shows the characteristics of RSS 1.0 documents.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.