HTMLSourceElement

The HTMLSourceElement interface provides special properties (beyond the regular HTMLElement object interface it also has available to it by inheritance) for manipulating <source> elements.

Properties

Inherits properties from its parent, HTMLElement.

Name Type Description
media DOMString Reflects the media HTML attribute, containing the intended type of the media resource.
src DOMString Reflects the src HTML attribute, containing the URL for the media resource.
type DOMString Reflects the type HTML attribute, containing the type of the media resource.

Methods

No specific method; inherits methods from its parent, HTMLElement.

Specifications

Specification Status Comment
WHATWG HTML Living Standard Living Standard No change from HTML5.
HTML5 Candidate Recommendation Initial definition.

Browser compatibility

Feature Chrome Firefox (Gecko) Internet Explorer Opera Safari (WebKit)
Basic support (Yes) 3.5 (1.9.1) (Yes) (Yes) (Yes)
Feature Android Firefox Mobile (Gecko) IE Phone Opera Mobile Safari Mobile
Basic support (Yes) 1.0 (1.9.1) (Yes) (Yes) (Yes)

See also

  • The HTML element implementing this interface: <source>.

Document Tags and Contributors

Contributors to this page: Sheppy, jswisher, ethertank, kscarfone, teoli
Last updated by: teoli,