HTML and CSS Reference
In-Depth Information
<Playlist>
<DisplayTimeCode>false</DisplayTimeCode>
<EnableCachedComposition>true</EnableCachedComposition>
<EnableCaptions>true</EnableCaptions>
<EnableOfline>true</EnableOfline>
<EnablePopOut>true</EnablePopOut>
<StartMuted>false</StartMuted>
<StartWithPlaylistShowing>false</StartWithPlaylistShowing>
<StretchNonSquarePixels>NoStretch</StretchNonSquarePixels>
<Items>
<PlaylistItem>
<AudioCodec>WmaProfessional</AudioCodec>
<Description></Description>
<FileSize>1349539</FileSize>
<FrameRate>25</FrameRate>
<Height>360</Height>
<IsAdaptiveStreaming>false</IsAdaptiveStreaming>
<MediaSource>silverlightvideos/Video2.wmv</MediaSource>
<ThumbSource></ThumbSource>
<VideoCodec>VC1</VideoCodec>
<Width>640</Width>
</PlaylistItem>
</Items>
</Playlist>'/>
<a href=" http://go2.microsoft.com/fwlink/?LinkID=124807" st yle="text-decoration: none;">
<img src=" http://go2.microsoft.com/fwlink/?LinkId=108181"
alt="Get Microsoft Silverlight" style="border-style: none;"/>
</a>
</object>
Notice how the <object> tag now includes many pieces of information. The <param> and <Playlist>
elements supply a great deal of data such as the path of the Silverlight compressed output file ( .xap ) and
the configuration of the video being played.
HTML5 Audio and Video Tags
In the previous sections, you learned how pre-HTML5 web applications play audio and video files using
<object> tag. Now let's turn our attention to HTML5 and see how HTML5 natively supports audio and
video playback.
HTML5 audio and video support comes in the form of the <audio> and <video> markup elements,
respectively. Each of these tags has a set of attributes you can use to configure how files are played.
Additionally, these elements expose properties, methods, and events that you can program using
JavaScript or jQuery. The following sections discuss the <audio> and <video> elements in detail.
Playing Audio
The HTML5 <audio> tag allows you to embed and play audio files in a web page. In its basic form, the
<audio> tag looks like Listing 3-4.
 
Search WWH ::




Custom Search