[Repost] Comprehensive introduction to Blog and RSS

zhaozj2021-02-12  211

Comprehensive introduction of Blog and RSS Original: Aaron Skonnard Translation: Northtibet Original Source: MSDN Magazine Apr. 2004 (The XML Files) What is Blog? "Blog" is a referusion of Web log (Translator Note: That is, a web). It is an intermediary with readers to interact with log styles. In the software community, people have become more and more popular in the form of a network. Such as: http://blogs.msdn.com is a blogging on the MSDN. What is the easiest way to build a network? To build your own web, the easiest way is to register a new user like blogger.com, which provides a web interface that creates a custom server, and you can use the created Weigns now. There are many sites like Blogger.com, which provide support for web-encyclopedia. If you want more to control the infrastructure of the net, you want to build a network service system on your own server. You can choose one of the most popular networks to apply commercial products: Radio Userland, Manila and Movable Type. Some are easy to use free .NET web network applications can be used, the most popular: .text and dasblog. Just download them down and then install and set according to the installation instructions, and a running network service system can be established in minutes. Functional speaking, these two .NET-based web-based application systems are not up and down. Its main difference is that .Text requires databases, SQL Server or MSDE, and Dasblog stores all information in the XML file (it is based on the Blogx framework created by some Microsoft developers), and the other difference is .Text in a single installation configuration Multiple webmarks can be supported (this is like this http://blogs.msdn.com), and Dasblog is to support multiple servings and must be installed multiple times. But Dasblog has a very prominent feature, which is "mail to weblog", which allows you to post new information through email. The new MSDN network service site and PDC Bloggers are all good destinations on software development topics. As long as you browse these sites, you can read the aggregated predetermined content. Its predetermined summary will open a lot of personal websites to you, and you will naturally find some content you prefer to read. This way, you can book your favorite personal network summary. For a web that specializes in XML and Web services, check out the list on the MSDN Web Services Developer Center, I personally spend a lot of time. What is Feed (hereinafter referred to as a feed), how to book it? The network provides a summary of the contents of the RSS document, which can be obtained by well known URL. The RSS document is an XML file that contains a large number of discrete news items, such as entry items in a web (see Figure 1 for the RSS Equation). Since RSS is an XML format file, it is easy to be used by other programs. The RSS aggregator is a program that reads the RSS document and displays the news item. Most aggregators use the URL of the RSS to make the predetermined summary possible. RSS makes reading the network easy. Most developers who often read the network have used some type of aggregator to help them filter the summary content.

The aggregator makes reading the Internet feel like reading emails because they highlight the news items and buffer the news items for offline reading (see Figure 2). There are also some online RSS aggregators to take RSS to bundle to a separate website. Its advantage is that it is easy to set up and you can access your feedn content from any computer. Of course, its disadvantages are also obvious, that is, it must always be connected when reading. RSS is the root of a powerful new information exchange form. Before the server appears, most developers usually spend a lot of time to filter off those who are unrelated. The network will give the control to the reader by letting the reader chooses the summary to read, so that the personalized content stream is effectively constructed. Other types of sites can also utilize the advantages of RSS to aggregate content. For example, most mainstream news sites include Wired, CNET, Yahoo, and NPR NEWS provide RSS feed. Access BlogDigger and Syndic8, you can find some sites that support RSS. Microsoft's MSDN provides RSS feeds to aggregate newly added to the site's technical content. MSDN's Just Public Published is a major way to keep MSDN new articles and downloads. Even MSDN Magazine (MSDN Magazine) has its own RSS feed! You can book: http://msdn.microsoft.com/msdnmag/rss/recent.xml Get every month update to see what is the content? There are currently many RSS aggregators to choose from http://blogs.law.harvard.edu/tech/directory/5/AGGREGATORS, you can find a fairly complete list. Some of them are online aggregators, while others are desktop applications. Some are free, and some other pay can be used. Which RSS version is most common? The answer to this question To see who you ask, the RSS version has a lot, 0.90, 0.91, 0.92, 0.93, 0.94, 1.0 and 2.0. It is necessary to figure out the difference between these versions is one of the huge challenges. Understand them need to know some historical backgrounds about them. Netscape created the initial version of RSS 0.90, the initial name is "RDF Site Summary" or "Rich Site Summary" (the former is a formal name in the specification). Netscape created RSS 0.90 for its web portal, this time, others saw RSS's use potential. Userland Software is one of the first one who started RSS for its network of business products. Version 0.90 is largely W3C-based Resource Description Framework (RDF). Many people think that RDF is too complicated, so it is recommended a free simplified version 0.91. This task gives Userland Software. Userland Software continues to develop the simplified version of RSS, and the released versions include: 0.92, 0.93 and 0.94. In order to emphasize its simplified work, they set the full name of the RSS as "Really Simple Syndication". Just when Userland Software continues to focus on its simplified work, another group of developers are revive the initial RDF version (0.90) because RSS is more flexible. They finally released a version of RSS 1.0, its official name or "RDF Site Summary". Due to the use of RDF, this version is completely different from the version controlled by the USERland Software.

Userland Software, is certainly not willing to see RSS 1.0 seems to replace its 0.94 version of the facts, so I have a new version, and jump the version number to 2.0. This is this situation today, forming two major competitive versions: one RDF 1.0, and the other is not (2.0), but they share the same name. This is a terrible confusion because the version number causes people to think that 2.0 is a 1.0 improvement version, and in fact they are completely different from two goals. Another group of developers have begun to solve this chaotic problem, by defining a new summary specification, the randomity of the RSS name. This solution is called Atom (atom) project. This article will be discussed in detail later. Which version is actually unrelated, most RSS aggregation mechanisms support all RSS versions (some even support Atom). The ultimate decision depends on whether you want to use RDF, it can be described as radish cabbage, each has love, it is completely depends on the semantic web concept of someone. What does RSS 1.0 and RSS 2.0 do? The core information contained in the RSS 1.0 and 2.0 format is the same, but its structure is different. I provided an RSS 1.0 document (see figure 1) and an equivalent RSS 2.0 (see figure 2) for control. You will notice the difference in root elements on the right side of the top line, the root element of RSS 1.0 is RDF: RDF, and the root element of RSS 2.0 is RSS. The RSS also includes a forced version attribute to indicate the exact format of the RSS used (possible values ​​including: 0.91, 0.94, etc.). Another major difference is that the RSS 1.0 document has a name space limit, and the documentation of RSS 2.0 is not. In any case, the information contained in two documents is essentially the same. The two versions contain the Channel elements, and the Channel element also contains three must-beat elements: Title, Description and Link, the code is as follows:>

In addition to these must-have elements, RSS 1.0 also defines three additional elements: image, items, and textinput, where image and textinput are optional. On the other hand, RSS 2.0 provides 16 additional elements, including Image, Items, and TextInput, there are also Language, Copyright, ManagingEditor, Pubdate, and Category. RSS 1.0 allows this type of metadata to be created by defining scalable elements in a separate XML namespace. These two formats in structure must be in the representation of their Item, Image, and TextInput nodes. In RSS 1.0, the Channel element contains references to Item, Image, and TextInput nodes, which exist outside the Channel node itself. This creates an RDF association between Channel and the referenced nodes. As shown in Figure 1, the CHANNEL element is associated with an Image element and two ITEM elements. In RSS 2.0, the ITEM element is only continuously discharged in the CHANNEL element (as shown in Figure 2). Item elements include actual news item information. The structure of the Item is the same in two versions. Item elements typically contain Title, Link, and Description elements, as shown in the following code:>

In RSS 1.0, Title and Link are must be, Description is optional. In RSS 2.0, Title or Description must provide one of them; others can choose. These just define the ITEM element in RSS 1.0. RSS 2.0 offers several other optional elements, including Author, Category, Comments, Enclosure, GUID, Pubdate, and Source. RSS 1.0 Gets such metadata is implemented by defining a scalable element called an RSS module in a separate XML name space. For example, in Figure 1, the date of item is used in DUBLIC CORE modules.

Element is represented. For complete information about different formats, please refer to

RSS 1.0

with

2.0

specification. So what is atom? I mentioned in front, Atom is a project name, mainly developing a new web summary format to solve the problem of the current RSS (the confusing version number, not a real open standard, indicating the inconsistency of the method, defining a poor definition and many more). Atom hopes to provide a clear version to solve everyone's needs, and its design is completely not dependent on the supplier, anyone can freely expand it, complete detailed description. Many BLOG engines today have supported the current summary format.

Figure 3

Is an atom 0.3 summary example, it is with the aforementioned

Figure 1

and

Figure 2

RSS is equivalent. Note that atom is defined with the namespace, but it does not use RDF. This makes Atom and RSS 1.0 and RSS 2.0 have similar places. If ATOM can be accepted in the future, people will wait and see. In addition to defining new summary formats, Atom also wants to define a standard file format and a standard server editing API (Atom API). For detailed specifications and other ATOM resources, please visit

THE Atom Project

. What is blogroll? Blogroll is a collection of netizen, most Blogger offers blogroll on its personal network. This allows the reader to connect to the number of people who have passed by other fun and writing style. Blogroll is convenient for communication on the network. By using Outline Processor Markup Language (OPML), people can exchange blogroll with XML format files. Figure 4

Is an example of blogroll. Most serve engines manage blogroll whenever they request blogroll to generate the corresponding XML format. Similarly, most of the aggregators can introduce blogroll and automatically book the summary included. See more information about OPML

http://opml.scripting.com

. Can I explain what REFERRERS, TRACKBACKS and PINGBACks are? Most servers can add a web commentary to readers. But more common practice is to let readers add an entrance to the original post in his own web. Bloggers is happy to track the time of connection, so that new readers can understand the entire session content. The so-called ReferRer is an external site, and the user clicks on a hyperlink on the site. You can reach your website. Many Week Zhi Engines can automatically keep track when readers navigate to an entrance to your web. Most engines will display a ReferRers list at the bottom of the network so that the reader can return to the ReferRer site and know what they want to say about the entrance. This is based on a hypothesis, that is if they link it, maybe What will be written here. The problem with ReferRer is that this hypothesis must be established - not enough information indicates whether the page referenced is in fact containing information. In fact, the publisher of the spam is re-directed to the reader in order to market attempts. Trackback and PingBack The same specification is used to make up for the above problems. Using Trackback and Pingback, other blogs automatically send a ping to your network to clearly indicate that they have written a reference to a particular post. This type of anti-chain allows your web to display all comments in a more obvious manner. Most of today's digital software supports all of these technologies. See

TRACKBACK TECHNICAL SPECIFICATION

with

Pingback 1.0

. How to generate RSS for my site?

Figure 5

For example, how to use the ASP: Repeater control to generate RSS 2.0 in the .aspx page. This page assumes that you have set the control DataSource property in the backend code file to the corresponding database result set. I want to aggregate several RSS and display the information on a personal website, can I explain how to implement it? Because the RSS will be an XML file, as an exercise, you can use our best at XML API, such as System.xml in Microsoft .NET Framework,

Figure 6

The ASP.NET web user control code is included, it is a piece of code I have written in the RSS of the BLOGROLL file (.OPML). This code assumes that the OPML element contains Numbertodisplay properties to indicate how many items you intend to display. Figure 7 ASP.NET Web User Control You can drag the control to any .aspx page, which will display the different items listed in the blogroll file, Figure 7 shows the effect screen of the UTAH .NET User Group website using this control . Is there a Web Services API with a network? Many webline engines offer their own web service interface, interacting with the network, but there is currently no standardized thing. Two .Text and Dasblog provide some .asmx endpoints, you can implement editing features through SOAP, but their interfaces are different. Blogger.com provides an XML-RPC-based interactive API (Blogger API)

). Userland Software enhances the function of Blogger API and called it

Metaweblog API

. These may be the recognized network APIS, but still not supported by all the network. There is also a unique API for adding comments called

Comment API

, Similar, it is not common support. The Atom group is working hard to solve these problems, and the Atom API defines a standard Weigns API for publishing and editing the content. For information, please refer to

THE Atom Project

website. Send problems and comments

AARON: XMLFILES@microsoft.com

.

About the author Aaron Skonnard lectures in the University of Salt Lake City. With people with "Essential XML Quick Reference" (Addison-Wesley, 2001), "Essential XML" (AdDison-Wesley, 2000), often speaking at meetings. You can contact him at http://www.skonnard.com. From the April 2004 Journal of MSDN Magazine, this article can be obtained through local newsstands, or it is best to subscribe.

This article is translated by vckbase mtt team

转载请注明原文地址:https://www.9cbs.com/read-7443.html

New Post(0)