CDF Overview

Channel Definition Format (CDF) is a Microsoft XML application for use with Internet Explorer. As mentioned in the introduction to this chapter, CDF enables automatic user notification when a Web site changes.

XML and Microsoft

XML has been steadily gaining support at Microsoft over the years. As of this writing, Microsoft has just indicated that the next version of Visual Studio, which is the host for such products as Visual Basic and Visual C++, is going to rely heavily on XML, as will MS Office applications.


How does CDF look in practice? Take a look at Figure 18.3. There, I've added a channel named Planets, complete with a simple icon, to Internet Explorer. To see the available channels, you click the Favorites button in Internet Explorer's button bar, which opens the Favorites bar as you see in Figure 18.3. (You can close the Favorites bar by clicking the X button at upper right in the bar.) The top folder in the Favorites bar is the Channels folder, which you click to open. The Channels bar shows the current channels, and the user has only to click a channel to download the channel's main page (channels can represent not only single pages, but whole Web sites).

Figure 18.3. Internet Explorer showing a new channel.


That's how channels work—when activated, the page or pages they represent are downloaded so that they may be viewed by the user without additional fetches from the Internet, even offline. Channel content may be downloaded on demand or on a set schedule. Besides a main page, most channels include a collection of other pages; we'll see how to create channel children, and how the user can access them, later in this chapter (see the later section "Adding <ITEM> Children").

How do channels actually work? The complete specification for a channel is stored in a CDF document, which is separate from other Web pages but usually linked to one of those Web pages. The user has only to open the CDF file—which usually means clicking a hyperlink with the text Subscribe to this page or something similar—to establish the channel in Internet Explorer. They can delete the channel later by removing it from the Favorites bar (for example, by right-clicking the channel and selecting the Delete item).

A fair number of CDF resources are available, nearly all of them at Microsoft. Microsoft did submit the specification for CDF to the W3C, and the W3C seems to have politely accepted it, posted it on its Web site, and done nothing else with it. Here's a starter list of CDF resources—keep in mind that Microsoft URIs change very frequently:

We might also note that Microsoft has a CDF generator; you can use this generator, which is free to download, to create CDF files. Here's how Microsoft describes it:

  • It has a simple and intuitive graphical interface that you will get used to in a few minutes.

  • It doesn't require previous knowledge of channels.

  • It supports all CDF tags.

  • It supports UTF-8 encoding.

  • It can also be used for testing purposes because it parses the CDF files and detects the errors.

  • It supports drag and drop, so there's less to type.

Microsoft also has another tool, which is even easier to use—the Channel Wizard. As of this writing, it is at http://msdn.microsoft.com/workshop/delivery/channel/cdfwiz/intro.asp. This tool lets you construct channels without knowing the first thing about CDF. This wizard asks you questions about the channel you want and generates the .cdf file and the link to it that you can embed in a Web page. This tool runs entirely online, and you can see it at work in Figure 18.4.

The Channel Wizard also provides dynamic HTML samples that will allow you to add special effects to your channel pages.

Microsoft supports the CDF File Verification Tool, which checks CDF files for validity, as well. As of this writing, this tool is at http://msdn.microsoft.com/downloads/tools/cdftest/cdftest.asp. You can use this tool to discover problems with CDF files, such as missing end tags and incorrect or misspelled tags. However, it doesn't run online; you must download this tool to use it.

That gives us an overview of CDF—it's time to start creating CDF files and channels.

Figure 18.4. The Microsoft Channel Wizard.


..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.145.154.185