1.1 Adding media to pages

LearnPress version: 1.5

Last modified: 8 September 2008

Contents

  1. Media as page objects
  2. Embedding media in the body text
    1. Syntax
      1. Attributes/content
    2. Tracking

Media as page objects

Embedding media in the body text

In addition to attaching media to pages as media objects, media (images, audio, video) can be embedded directly into the body text of a page using the <obj> pseudo-element.

Syntax

To place an image, audio file, or video file in the flow of a page’s body text, add the following code:

<obj id="####" style="CSS" download="true|false" linkRecord="true|false" showCredit="true|false">Caption</obj>

The <obj> element is not a valid HTML element and will be ignored outside of LearnPress. When used in LearnPress, it will be converted on display to the appropriate elements for display of the requested media.

<obj> should be treated as a block-level element.

Attributes/content

id
Required. The media_ID of the media record to be embedded.
style
Optional. Inline styling information. Use any normal CSS specifications. Note: Styles will display only on the web, not in PDF output. See “PDF Output” for information on print styling of embedded media.
download
Optional. Accepted values are true (default for audio/video) and false. If true, displays a link to download the media file. Ignored for images and documents.
linkRecord
Optional. Accepted values are true and false (default). If true, displays a link to the media record.

showCredit
Optional. Accepted values are true (default) and false. If true and a caption is specified, displays media credit after the caption.

caption
Optional. Any information inside the element will display as a caption. Captions are considered inline content and may include other inline elements (e.g. em).

Tracking

Media embedded using <obj> are listed as media objects on the page record, with priority 0. The object records cannot be edited or deleted but reflect the use of <obj> pseudo-elements in the body text field.