source (HTML5)

The source element is used to specify multiple media resources for audio and video elements in HTML5.

Properties & Events

KeyDescriptionAvailability
mediaMedia query of the resource's intended media.
chrome 1.0safari ??Firefox 3.6ie 9.0opera 1.0
srcRequired, address of the media resource.
chrome 1.0safari ??Firefox 1.0ie 1.0opera 1.0
typeThe MIME-type of the resource, optionally with a codecs parameter.
chrome 1.0safari ??Firefox 3.6ie 9.0opera 1.0

Examples having uses of: 'source'

1 votes
10k views

HTML5 source

The <source> tag is used to specify multiple media resources for media elements, such as <video> and <audio>. The <source> tag allows you to specify alternative video/audio files which the browser may choose from, based on its media type or codec support.
10 votes
10k views

HTML5 Video

The HTML5 <video> element also has methods, properties, and events and methods for playing, pausing, and loading, for example. Properties (e.g. duration, volume, seeking) that you can read or set. There are also DOM events that can notify you, for example, when the <video> element begins to play, is paused, is ended, etc.
4 votes
8k views

HTML5 audio

The <audio> tag defines sound, such as music or other audio streams. Tip: Any text inside the between <audio> and </audio> will be displayed in browsers that do not support audio.
0 votes
0 views

The HTML5 source tag

The <source> tag is used to specify multiple media resources for media elements, such as <video> and <audio>. The <source> tag allows you to specify alternative video/audio files which the browser may choose from, based on its media type or codec support.