HTML DOM Samp Object

Samp Object The Samp object represents an HTML <samp> element. Access a Samp Object You can access a <samp> element by using getElementById(): Example var x = document.getElementById(“mySamp”); Try it Yourself » Create a Samp Object You can create a <samp> element by using the document.createElement() method: Example var x = document.createElement(“SAMP”); Try it Yourself » Standard […]

HTML <track> label Attribute

Example A video with two subtitle tracks, both with a label defined: <video width=”320″ height=”240″ controls> <source src=”forrest_gump.mp4″ type=”video/mp4″>  <track src=”subtitles_en.vtt” kind=”subtitles” srclang=”en” label=”English”> <track src=”subtitles_no.vtt” kind=”subtitles” srclang=”no” label=”Norwegian”> </video> Definition and Usage The label attribute specifies the title of the text track. The title of the text track is used by the browser when listing available text tracks. Browser Support The numbers in the table specify the […]

HTML DOM Aside Object

Aside Object  The Aside Object is new in HTML5. The Aside object represents an HTML <aside> element. Note: The <aside> element is not supported in Internet Explorer 8 and earlier versions. Access an Aside Object You can access an <aside> element by using getElementById(): Example var x = document.getElementById(“myAside”); Try it Yourself » Create an Aside Object […]