HBCMS更多的中文手册参考:

playList Collection

DHTML中文手册

Retrieves a collection of playitem objects.

dhtml语法

[ ocoll = ] object.playlist
[ oobject = ] object.playlist(iindex)

dhtml可能的值

ocollarray of elements contained by the object.
oobjectreference to an individual item in the array of elements contained by the object.
iindexrequired. integer that specifies the zero-based index of the item to be returned.

members table

AttributePropertyDescription
activeTrack Sets or retrieves the track, or playItem object, that is currently active in the playList collection.
banner   Retrieves the Banner content of an entry in an Advanced Stream Redirector (ASX) file.
bannerabstract   Retrieves the BannerAbstract content of an entry in an ASX file.
bannermoreinfo   Retrieves the bannermoreinfo content of an entry in an asx file.
durdur Sets or retrieves a value indicating the amount of time the element remains active or displayed.
length Retrieves the number of objects in a collection.
MethodDescription
item Retrieves an object from the specified collection.
nextTrack Advances the media-playing container to the next track, or playItem object, in the playList collection, and begins playing that track.
prevTrack Sets the media-playing container to the previous track, or playItem object, in the playList collection and begins playing that track.
ObjectDescription
playItem Represents an individual media file in a playList collection.

Remarks

Some media file formats contain several individual media files, such as an MPEG-Layer 3 (MP3) playlist that contains several MP3 files. This collection provides access to those individual media files.

The playList collection is available only while the parent element is active on the timeline. When the parent element's timeline ends, this collection is no longer available.

DHTML代码范例

This example demonstrates how to retrieve a collection of playItem objects using the playList collection.

<HTML XMLNS:t="urn:schemas-microsoft-com:time">
<HEAD>
<?IMPORT namespace="t" implementation="#default#time2">
<STYLE>
.time{ behavior: url(#default#time2);}
</STYLE>
<SCRIPT LANGUAGE="JavaScript">
function updateBtns() {
if(m1.currTimeState.isActive){
b0.disabled=true;
b1.disabled=false;
b2.disabled=false;
b3.disabled=false;
}else{
b0.disabled=false;
b1.disabled=true;
b2.disabled=true;
b3.disabled=true;
}
}
function updateFields(){
title1.innerText = 'Title: ' + m1.playList.activeTrack.title;
author1.innerText = 'Author: ' + m1.playList.activeTrack.author;
abstract1.innerText = 'Abstract: ' + m1.playList.activeTrack.abstract;
copyright1.innerText = 'Copyright: ' + m1.playList.activeTrack.copyright;
}
function emptyFields(){
title1.innerText = 'Title: ';
author1.innerText = 'Author: ';
abstract1.innerText = 'Abstract: ';
copyright1.innerText = 'Copyright: ';
}
</SCRIPT>
</HEAD>
<BODY onload="updateBtns()" TOPMARGIN=0 LEFTMARGIN=0 BGPROPERTIES="FIXED"
BGCOLOR="#FFFFFF" LINK="#000000" 	VLINK="#808080" ALINK="#000000">
...
<t:media id="m1" src="../../common/samples/author/behaviors/media/media.asx"
onmediacomplete="updateFields();updateBtns();"/>
<SPAN id="title1">Title:</SPAN><BR>
<SPAN id="author1">Author:</SPAN><BR>
<SPAN id="abstract1">Abstract:</SPAN><BR>
<SPAN id="copyright1">Copyright</SPAN><BR><BR>
<BUTTON id="b0" onclick="m1.beginElement();updateFields();updateBtns();">Start</BUTTON>
<BUTTON id="b1" onclick="m1.playList.nextTrack();updateFields();">Next Track</BUTTON>
<BUTTON id="b2" onclick="m1.playList.prevTrack();updateFields();">Previous Track</BUTTON>
<BUTTON id="b3" onclick="m1.endElement();emptyFields();updateBtns();">Stop</BUTTON>
<BR><BR>
</BODY>
</HTML>
This feature requires Microsoft?Internet Explorer 5.5 or later. Click the following icon to install the latest version. Then reload this page to view the sample.

是否符合公共标准

This collection is a Microsoft extension to Synchronized Multimedia Integration Language (SMIL) Non-Microsoft link.

Applies To

t:AUDIO, t:MEDIA, t:REF, t:VIDEO

更多语法参考

Introduction to HTML+TIME