Click Here to Install Silverlight*
United StatesChange|All Microsoft Sites
Windows Media Player 9 Series
|Windows Media Worldwide

Creating Customized Web Experiences with Windows Media Player 9 Series

Jim Travis
Microsoft New Media Platforms Division
November 2002


Introduction

Windows Media Player 9 Series provides new functionality that allows you to customize what users see when they use the Player to view your content. This functionality also provides new opportunities for revenue generation. This document describes the following new features:
  • Using HTML, Microsoft JScript®, and XML, you can easily create an interactive, Web-based experience that is displayed in the Windows Media Player Now Playing feature.
Feedback
E-mail us with your comments and feedback about this article.
 
Abstract
This document describes how to use new features available in Microsoft® Windows Media® Player 9 Series to create and display customized Web content that is integrated with the Player.
  • Windows Media Player 9 Series can play new types of interstitial advertisements.

  • Subscription service providers can offer subscriptions and manage downloading content by creating an integrated experience in the Windows Media Player Premium Services feature.

This document contains the following topics:
Back to the top of this page Back to the top


Displaying Web Pages in Windows Media Player

When playing digital media using Windows Media Player, a user usually sees the video content (if the file contains video) or a visualization (if the file contains only audio). Windows Media Player 9 Series allows you to use the area where video and visualizations normally display to present Web-based content. This approach has several advantages:
  • Web-based advertising displayed in the Player user interface has greater impact.

  • A Web page can provide links to similar content, thereby creating new selling opportunities.

  • The integrated experience is better for both users and advertisers when compared to pop-up ads.
Example of a Web page displayed using HTMLView
Figure 1: Example of a Web page displayed using HTMLView


Using Windows Media Metafiles
Windows Media metafiles are text files that provide information about a file stream and its presentation. Based on Extensible Markup Language (XML) syntax, Windows Media metafiles can contain a variety of elements, each identified by a tag with associated attributes. A typical use of a Windows Media metafile is to create a metafile playlist.

The PARAM element provides a way to associate a custom parameter with either a particular entry in a metafile playlist, or with the entire metafile. One of the predefined parameter names available for your use is HTMLView. Specifying a value for the HTMLView parameter causes the Web page specified by the Uniform Resource Locator (URL) value to display in Windows Media Player.

The following example code demonstrates a Windows Media metafile with two entries. In this case, the HTMLView parameter is associated with the entire metafile:

<ASX version="3.0">
<PARAM name="HTMLView" value="http://www.proseware.com/htmlview.htm"/>

<ENTRY>
<REF href="rtsp://www.proseware.com/content1.wma"/>
</ENTRY>

<ENTRY>
<REF href="rtsp://www.proseware.com/content2.wma"/>
</ENTRY>

</ASX>

You can easily change the Web page that displays for each piece of content by associating a PARAM element with each entry, as the following code example shows:

<ASX version="3.0">

<ENTRY>
<REF href="rtsp://www.proseware.com/content1.wma"/>
<PARAM name="HTMLView" value="http://www.proseware.com/htmlview1.htm"/>
</ENTRY>

<ENTRY>
<REF href="rtsp://www.proseware.com/content2.wma"/>
<PARAM name="HTMLView" value="http://www.proseware.com/htmlview2.htm"/>
</ENTRY>

</ASX>

When you specify a value for HTMLView, Windows Media Player displays the specified Web page by using an embedded instance of Microsoft Internet Explorer. This greatly simplifies the task of creating the Web content because the page can be authored specifically for that browser. Your Web page can also contain an embedded instance of the Windows Media Player 9 Series ActiveX® control. This allows you to access the wide range of functionality available through the Player object model simply by using a scripting language like Microsoft JScript. When you embed the Player control in this manner, the control shares the playback engine of the Player application. This means that the normal transport controls work for the embedded Player instance, providing the user with a completely integrated experience.

The recommended size for Web pages displayed using HTMLView is 387345 pixels.

Back to the top of this page Back to the top


Interstitial Advertisements

Interstitial advertisements are a type of digital media content. Like television or radio ads, interstitial ads play between parts of the regular program. This type of advertising can be very effective because the advertiser already has the attention of the audience. Windows Media Player 9 Series provides improved support for this type of advertising in the following ways:
  • The Player supports a wider range of formats, including Macromedia Flash, JPG, GIF, animated GIF, and BMP.

  • Performance during seamless transitions is greatly improved, including seamless transitions between different formats. Transitions are even faster when using Fast Start technology, which is available when using Windows Media Services 9 Series.
You can easily include interstitial ads in your program by using the same Windows Media metafile playlist technology discussed in the previous section. The following example code shows a metafile playlist that inserts a Flash presentation between two entries. The DURATION element ensures that the program switches to the next entry after exactly ten seconds:

<ASX version="3.0">

<ENTRY>
<REF href="rtsp://www.proseware.com/content1.wma"/>
</ENTRY>
<ENTRY>
<REF href="http://www.proseware.com/flashad.swf"/>
<DURATION value="00:00:10.00"/>
</ENTRY>
<ENTRY>
<REF href="rtsp://www.proseware.com/content2.wma"/>
</ENTRY>

</ASX>

Back to the top of this page Back to the top


Subscription Service Integration

Windows Media Player 9 Series includes an architecture and software development kit (SDK) that enables digital media subscription service providers to integrate their services with the Player by using the Premium Services feature. Users expect an integrated experience from a digital media subscription service, including the ability to locate content, download and manage files, play content, and copy music to CDs or devices. Windows Media Player includes user interface elements that offer subscription services to the user, identify and organize Media Library content as subscription content, and allow the user to manage subscription services.

The Player provides a way for service providers to promote their services. Through a default Web page displayed in the Windows Media Player Premium Services feature, users can discover and explore subscription services offered by providers that meet a standard set of business and technical requirements. Placement on this Web page requires a license agreement with Microsoft Corporation. Contact your Microsoft business development representative for details.

Windows Media Player Premium Services feature
Figure 2: Windows Media Player Premium Services feature


In order to be visible to the user in Windows Media Player, subscription services create a set of registry keys that identify the service. Once registered, the subscription service provider manages the entire relationship with the customer. When a user chooses to interact with a registered service, Windows Media Player displays a Web page authored by the subscription service provider. This Web page, combined with an ActiveX control or other COM component installed by the provider, manages subscription content and enables background processing tasks like downloading content and managing licenses.

Download Manager Simplifies Transferring Content to the User's Computer
Windows Media Player Download Manager provides an object model that you can use to handle the tasks associated with downloading content to the user's computer from a server using Hypertext Transfer Protocol (HTTP). With Download Manager, service providers can:
  • Manage multiple downloads simultaneously as a collection.

  • Specify a URL for a file and start it downloading using HTTP.

  • Query for the download state and progress.

  • Pause, resume, or cancel a download.

  • Specify whether a download occurs in the background or in real time. (Background downloading is only available on the Microsoft Windows® XP operating system.)

Using Download Manager is easy. Registered subscription service providers can access Download Manager and related objects using JScript code in Web pages displayed in the Premium Services feature.

Download Manager is integrated with My Music and Media Library. Based on metadata associated with downloaded content, Windows Media Player automatically creates the appropriate folder structure in the user's My Music folder and adds the content to Media Library. If the digital media file contains a value for the WM/ContentDistributor metadata attribute, the Player automatically adds the content to the Premium Services node in Media Library as well. These features provide the user with a standard and familiar way of organizing subscription content.

Enhanced Support for DRM and Background Processing
If a registered subscription service provider installs a custom COM component on the user's computer, the component can implement methods that Windows Media Player calls when the user initiates certain processes. This allows the subscription service to be tightly-coupled with the core functionality of the Player. For example, a subscription service can use these methods to acquire play count data or to renew expired licenses.

To take advantage of these features, the subscription service component implements the IWMPSubscriptionService interface, which contains four methods:
  • The allowCDBurn method manages permission for the Player to write subscription content to a CD.

  • The allowPDATransfer method manages permission for the Player to copy subscription content to a device.

  • The allowPlay method manages permission for the Player to play protected content. This gives the subscription service an opportunity to disallow playback or to initiate download of a new license. (The method never circumvents digital rights management (DRM); if the license has expired, the content won't play.)

  • The startBackgroundProcessing method is called after the user has clicked the Premium Services tab in Windows Media Player. This gives the service an opportunity to perform background tasks like acquiring play count data.

Back to the top of this page Back to the top


For More Information


Back to the top of this page Back to the top


Legal Notice

The information contained in this document represents the current view of Microsoft Corporation on the issues discussed as of the date of publication. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information presented after the date of publication.

This White Paper is for informational purposes only. MICROSOFT MAKES NO WARRANTIES, EXPRESS OR IMPLIED, AS TO THE INFORMATION IN THIS DOCUMENT.

Complying with all applicable copyright laws is the responsibility of the user. Without limiting the rights under copyright, no part of this document may be reproduced, stored in or introduced into a retrieval system, or transmitted in any form or by any means (electronic, mechanical, photocopying, recording, or otherwise), or for any purpose, without the express written permission of Microsoft Corporation.

Microsoft may have patents, patent applications, trademarks, copyrights, or other intellectual property rights covering subject matter in this document. Except as expressly provided in any written license agreement from Microsoft, the furnishing of this document does not give you any license to these patents, trademarks, copyrights, or other intellectual property.

© 2002 Microsoft Corporation. All rights reserved.

Microsoft, MS-DOS, Windows, Windows Media, Windows NT, ActiveSync, ActiveX, Direct3D, DirectDraw, DirectInput, DirectMusic, DirectPlay, DirectShow, DirectSound, DirectX, FrontPage, JScript, Microsoft Press, MSN, NetShow, Outlook, PowerPoint, SQL Server, Visual Basic, Visual C++, Visual InterDev, Visual J++, Visual Studio, WebTV, Win32, and Win32s are either registered trademarks or trademarks of Microsoft Corporation in the U.S.A. and/or other countries.

The names of actual companies and products mentioned herein may be the trademarks of their respective owners.

This software is based in part on the work of the Independent JPEG Group.

GIF decompression code, copyright 1990, David Koblas. Permission to use, copy, modify, and distribute this software and its documentation for any purpose and without fee is hereby granted, provided that the above copyright notice appear in all copies and that both that copyright notice and this permission notice appear in supporting documentation. This software is provided "as is" without express or implied warranty.


Back to the top of this page Back to the top



© 2009 Microsoft Corporation. All rights reserved. Contact Us |Terms of Use |Trademarks |Privacy Statement
Microsoft