Close this window

Using the <media> tag

Description

The media tag is used to insert media objects into a CNXML document. The media objects can be images, applets, movies, sounds, or any object with a valid MIME type.

Note:

Starting with version 0.6, the CNXML language does not permit URLs that contain ampersand (&) characters (i.e., http://cnx.org/example?i=1&p=2). Check all media src URLs and replace any ampersands with the entity reference "&amp;". More information can be found on the W3C's page.

Example

This CNXML:


<media id="dog_on_couch"
       alt="A dog sitting on a couch.">
	   
  <image mime-type="image/jpeg"
         src="image1.jpg" />
		 
</media>
        

Results in this display:

A dog sitting on a couch

Attributes(what's this?)

Children(what's this?)

audio, flash, video, java-applet, image, labview, download

Parents(what's this?)

preformat (media must be block display), para, title, label, cite, cite-title, link, emphasis, term, sub, sup, quote (media must be block display), foreign, footnote, equation, note (media must be block display), item, code (media must be block display), figure, subfigure, caption, commentary, meaning, entry, statement, proof, problem, solution, content (media must be block display), section (media must be block display)
Close this window