Overview
The HTML code for the embedded RealPlayer has the following general structure:
<OBJECT ID="RealPlayer"
CLASSID="clsid:CFCDAA03-8BE4-11cf-B84B-0020AFBBCCFA"
HEIGHT = "390" WIDTH =
"360">
<param name="SRC"
value="http://www.surfnet.nl/cgi-bin/play.php/force_real.ram?url=/n/naam/dz1626.mpg&start=23.1&end=68.9">
<param
name="AUTOSTART" value="FALSE">
<param name="CENTER"
value="FALSE">
<param name="IMAGESTATUS" value="TRUE">
<param
name="LOOP" value="FALSE">
<param name="MAINTAINASPECT"
value="TRUE">
<param name="NOJAVA" value="TRUE">
<param
name="NUMLOOP" value="">
<param name="SHUFFLE"
value="FALSE">
<param name="CONTROLS"
value="ImageWindow,ControlPanel,Statusbar">
<embed
NAME="RealPlayer"
SRC="http://www.surfnet.nl/cgi-bin/play.php/force_real.ram?url=/n/naam/dz1626.mpg&start=23.1&end=68.9">
type="audio/x-pn-realaudio-plugin"
HEIGHT
="390"
WIDTH ="360"
AUTOSTART ="FALSE"
CENTER ="FALSE"
IMAGESTATUS
="TRUE"
LOOP ="FALSE"
MAINTAINASPECT ="TRUE"
NOJAVA ="TRUE"
NUMLOOP
=""
SHUFFLE ="FALSE"
CONTROLS ="ImageWindow,ControlPanel,Statusbar">
</embed>
</OBJECT>
This code consists of an <OBJECT> tag and an <EMBED> tag. The
<OBJECT> tag is interpreted by Internet Explorer, but is ignored by
Netscape. The OBJECT tag handles the embedding of an ActiveX component.
Netscape uses the EMBED tag for embedding a Netscape plugin. The combination
of both tags ensures a correct replay of the clip in both browsers.
Setting options
The easiest way to set common options is by using the Virtual Cutter. However, you can manually add options that are not included in the generated HTML code. An overview of all options is presented below. Note that you must specify the options for both the OBJECT and the EMBED tag.
OBJECT tag parameters
Add the line below. Replace [parameter name] by the name of the
parameter and [value] by the value of the parameter.
<param name= '[parameter name]' value ='[value]'>
An example:
In order to set the value of the parameter 'AUTOSTART' to 'true', add the following
line underneath the other lines (but before the ">"):
<param name='AUTOSTART' value='true'>
EMBED tag parameters
Add the line below. Replace [parameter name] by the name of the
parameter and [value] by the value of the parameter.
<param name='[parameter name]' value='[value]'>
An example:
In order to set the value of the parameter 'LOOP' to true 'true', add
the following line underneath the other lines (but before the EMBED tag):
'LOOP' ='true'
Overview of the options
Below you will find the options with which you can modify the behaviour of the embedded RealPlayer to your wishes. Include the options in the generated HTML code as described above. The following guidelines apply:
OBJECT tag
- The reserved words PARAM, NAME and VALUE are not case sensitive.
- Parameter names are not case sensitive.
- The same holds for parameter values. Note that file names must often be specified in
lowercase.
- Parameter values must always be enclosed in double quotation marks.
EMBED tag
- Parameter names are not case sensitive.
- The same holds for parameter values. Note that file names must often be specified in
lowercase.
- There is no need to put quotation marks around the parameter values,
unless the value is an URL (file location).
Only examples for the EMBED tag are provided.
AUTOGOTOURL
Specifies how to handle URLs embedded in a presentation.
| Value(s) | true or false |
| Default value | true |
| Compatibility | RealPlayer 5 or later |
When set to TRUE, AUTOGOTOURL passes all URLs embedded in your presentation to the browser. When set to FALSE, RealPlayer sends the URLs to a Java applet or other application via the OnGotoURL callback.
AUTOSTART
Specifies whether to automatically play a presentation.
| Value(s) | true or false |
| Default value | true |
| Compatibility | RealPlayer 5 or later |
When set to TRUE, AUTOSTART instructs the Embedded RealPlayer to automatically begin playing the presentation once the source content is available.
BACKGROUNDCOLOR
Sets the background color for the image window. When a clip includes transparent regions, the background color also shows through these areas.
| Value(s) | colour name or RGB hex value |
| Default value | black |
| Compatibility | RealPlayer G2 or later |
The background color is specified using an RGB hexadecimal colour value or a colour name. The following table lists the valid background colour values:
CENTER
Specifies whether the presentation should be centered in the image window and displayed in its original, encoded size.
| Value(s) | true or false |
| Default value | false |
| Compatibility | RealPlayer G2 or later |
When the CENTER parameter is set to TRUE, the presentation is centered in the image window and the height and width of the presentation are reset to the original dimensions specified at the time of encoding. When CENTER is set to FALSE, the presentation is not centered and the height and width of the presentation are allowed to expand and fill the image window.
Warning! CENTER and MAINTAINASPECT cannot both be TRUE.
CLASSID
Identifies an ActiveX control as belonging to the RealPlayer class.
| Value(s) | clsid:CFCDAA03-8BE4-11cf-B84B-0020AFBBCCFA |
| Default value | (none) |
| Compatibility | ActiveX only, RealPlayer 5 or later |
An Embedded RealPlayer ActiveX control must include the RealPlayer classID value in the <OBJECT> tag definition and the value must be enclosed in double quotation marks. If you do not include this parameter in your tag definition, or you specify an invalid value, the browser will not load your presentation and may issue an error message.
<OBJECT ID=... CLASSID="clsid:CFCDAA03-8BE4-11cf-B84B-0020AFBBCCFA"
... >
CONSOLE
Specifies whether multiple controls (for example start and stop buttons, volume control) should be linked together to manage playback of a single embedded presentation.
| Value(s) | Shared name, _master or _unique |
| Default value | _unique |
| Compatibility | RealPlayer 5 or later |
When the same console name is specified for multiple control on a web page, this parameter can be used to enable these controls to manage playback of a single embedded presentation. For example, if you have multiple play and stop buttons on the same page, a shared console name enables them to control the same clip. The following table lists the valid console name values:
CONTROLS
Embeds the specified RealPlayer control on your Web page. For a complete listing of valid control name values, see RealPlayer website.
| Value(s) | control name |
| Default value | All |
| Compatibility | RealPlayer 5 or later |
If you do not include this parameter in your tag definition, then the basic RealPlayer control panel is added to your Web page.
HEIGHT
Sets the height of the image window or a specified embedded control.
| Value(s) | a number of pixels or percentage of browser window size. |
| Default value | (none) |
| Compatibility | RealPlayer 5 or later |
Setting the HEIGHT or WIDTH to zero causes the control to be hidden. If you do not include this parameter in your image window tag definition, the window may appear as a tiny icon because streaming media presentations do not size automatically.
ID
Identifies the embedded presentation for referencing in a scripting language
| Value(s) | any unique identification string |
| Default value | (none) |
| Compatibility | ActiveX only, RealPlayer 5 or later |
When you intend to use a scripting language such as VBScript to control your presentation, you must specify a unique value for the ID parameter. For example:
<OBJECT ID=realplayer CLASSID="clsid:CFCDAA03-8BE4-11cf-B84B-0020AFBBCCFA">
<PARAM NAME="SRC" VALUE="file://my_content.rpm">
<PARAM NAME="CONTROLS" VALUE="ImageWindow">
...
</OBJECT>
You can then use the scripting language to control the presentation. For example:
<FORM>
<input TYPE="button" VALUE="Play" NAME="doplay">
<script LANGUAGE="VBScript" FOR="doplay"
EVENT="onClick">
realplayer.DoPlay
</script>
</FORM>
IMAGESTATUS
Specifies whether the status information should be written along the bottom of the image window.
| Value(s) | true or false |
| Default value | true |
| Compatibility | RealPlayer 5 or later |
When set to TRUE, then the status information is written along the bottom of the image window (default). Status information includes duration and current position of the presentation.
LOOP
Specifies whether playback of the clip should continue, or loop, indefinitely.
| Value(s) | true or false |
| Default value | false |
| Compatibility | RealPlayer G2 or later |
When set to TRUE, playback of the clip continues to loop until the user stops the presentation. When LOOP is set to false, or if the parameter is not included in the tag definition, then the presentation stops after the first playback (default).
MAINTAINASPECT
Specifies whether the height-to-width (aspect) ratio of the clip should stay constant when the clip scales to fit the image window.
| Value(s) | true or false |
| Default value | false |
| Compatibility | RealPlayer G2 or later |
If the MAINTAINASPECT parameter is set to TRUE, the aspect ratio of the clip
remains constant when the image window is resized. When this occurs, the
clip is centered in the image window and scaled until one dimension reaches
the window's boundaries and the other dimension is within the boundaries.
If the MAINTAINASPECT parameter is set to FALSE, or if it is not included in the
tag definition, then the dimensions of the clip scale as necessary to allow the
clip to completely fill the image window (default). When the dimensions of
the clip are allowed to change in this manner, the source image may appear
distorted.
Warning! CENTER en MAINTAINASPECT cannot both be set to
TRUE.
NAME
Specifies the name to associate with an embedded RealPlayer control, to enable the control to be referenced using JavaScript.
| Value(s) | any unique name |
| Default value | (none) |
| Compatibility | Netscape only, RealPlayer 5 or later |
In order to refer to an embedded RealPlayer control from JavaScript, you must
specify a unique name for the control.
For example:
<EMBED NAME=realplayer SRC="..." WIDTH=176 HEIGHT=132>
The control can then be referenced by a JavaScript command, such as the following:
<Input Type="button" Value="play" onClick="document.realplayer.DoPlay()">
Warning! In Netscape versions 4.x, you can only reference named controls from JavaScript, when the NOJAVA parameter is not set to TRUE. If NOJAVA = TRUE is included in your <EMBED>= tag, the browser's Java Virtual Machine (JVM) is prevented from starting if it is not yet running, and control referencing from JavaScript is not available.
NOJAVA
Prevents the Java Virtual Machine (JVM) from starting, if it is not yet running, and makes the use of JavaScript impossible.
| Value(s) | true or false |
| Default value | false |
| Compatibility | Netscape version 4.x only, RealPlayer G2 or later |
When NOJAVA is set to FALSE ***(IS FOUT IN NL VERSIE), or if the parameter is not included in your control tag definition, the JVM is started and NAMED controls can be referenced from JavaScript. However, because starting the JVM delays presentation playback, it is highly recommended that you specify NOJAVA = TRUE ***(IS FOUT IN NL VERSIE)in the tag definition for every control, when you do not intend to use scripting.
Internet Explorer en Netscape 6.x launch the JVM on browser start-up and ignore this parameter.
NOLABELS
Specifies whether the title, author, and copyright information for a presentation should be displayed in RealPlayer. This parameter is obsolete and should only be used to provide backward compatibility with RealPlayer 5.
| Value(s) | true or false |
| Default value | false |
| Compatibility | Netscape only, RealPlayer 5 or later |
When the NOLABELS parameter is set to TRUE, the title, author, and copyright information is not displayed.
NOLOGO
Specifies whether the RealNetworks logo should be displayed in the image window when no clip is playing.
| Value(s) | true or false |
| Default value | false |
| Compatibility | RealPlayer G2 or later |
When NOLOGO is set to TRUE, ***[zinsdeel geknipt vanwege FOUT IN DE NL VERSIE] the RealNetworks logo is not displayed in the image window when no clip is playing. The image window then defaults to black unless anopther background colour is specified using the BACKGROUND parameter.
NUMLOOP
Specifies the number of the times the presentation should loop during playback.
| Value(s) | any number |
| Default value | (geen) |
| Compatibility | RealPlayer G2 or later |
When the NUMLOOP parameter has been set to a number value, the presentation loops (plays from beginning to end) the specified number of times and then stops. If you do not include the NUMLOOP parameter in your tag definition (default), then the presentation only loops if the LOOP parameter has been specified.
Warning! If both NUMLOOP and the LOOP have been specified, the LOOP parameter is ignored. This condition still applies even if NUMLOOP has been set to zero.
PARAM
Used to specify additional parameters in an ActiveX control <OBJECT> tag definition.
| Value(s) | any parameter described in this chapter, except NAME (DEAD LINK) |
| Default value | (none) |
| Compatibility | ActiveX only, RealPlayer 5 or later |
Additional parameters are specified via the PARAM parameter, using this syntax:
<PARAM NAME="name" VALUE="value">
The NAME variable can be assigned any of the parameters described in this chapter, except for the NAME parameter. To specify a name for a control in your ActiveX control <OBJECT> tag defintion, use the ID parameter instead. The VALUE variable should be assigned the appropriate value for the parameter specified in NAME.
PREFETCH
Enables or disables PREFETCH playback mode, which causes RealPlayer to get the stream description information from a presentation before playback begins.
| Value(s) | true or false |
| Default value | false |
| Compatibility | RealPlayer 5 or later |
When RealPlayer detects that prefetch playback mode is enabled, the presentation's stream description information is obtained. After the information has been captured, the presentation is paused. You can use the information to change control or playback characteristics. You can then change the height and width of the image window, for example.
REGION
Defines the web page playback region for a SMIL clip.
| Value(s) | SMIL region |
| Default value | (none) |
| Compatibility | RealPlayer G2 or later |
Clips listed in a SMIL file include specifications in their tags, which indicate where the clip should be played back in a web page. For example, if the 'newsarticle.rt' file should be displayed in the 'article' playback region of a newspaper web page, it is listed as:
<textstream src="newsarticle.rt" region="article " />
In order to view 'newsarticle.rt' on the newspaper web page, an image window control has to be created and it's playback region has to be set to 'article' using the REGION parameter.
Netscape plug-in:
<EMBED SRC="http://realserver.example.com:8080/ramgen/newspaper.smil?embed"
WIDTH=176 HEIGHT=132
NOJAVA=true CONTROLS=ImageWindow
ActiveX object:
<OBJECT ID=RVOCX CLASSID="clsid:CFCDAA03-8BE4-11cf-B84B-0020AFBBCCFA"
WIDTH=176
HEIGHT=132>
<PARAM NAME="SRC" VALUE="http://realserver.example.com:8080/ramgen/newspaper.smil">
<PARAM NAME="CONTROLS" VALUE="ImageWindow">
<PARAM NAME="REGION" VALUE="article">
</OBJECT>
SCRIPTCALLBACKS
Specifies the callback events to handle via a comma separated list.
| Value(s) | any callback (consult the Real website) or All |
| Default value | (none) |
| Compatibility | Netscape version 6.x only, RealPlayer 5 or later |
The SCRIPTCALLBACKS parameter can be used by Netscape version 6.x plug-ins, to specify the set of callback events you would like to capture and handle. The events are assigned to the parameter via a comma separated list, such as:
<SCRIPTCALLBACKS=OnPresentationOpened,OnPresentationClosed>
SHUFFLE
Specifies whether all unplayed clips in a presentation, should be played back in a random order. This parameter can be used for multiclip RAM files (.RAM or .RPM) or SMIL files that contain only a sequence of clips.
| Value(s) | true or false |
| Default value | false |
| Compatibility | RealPlayer G2 or later |
When the SHUFFLE parameter is set to TRUE, all unplayed clips in a presentation are played back in a random order, rather than in the order in which they appear in the file.
SRC
Specifies the URL of the presentation to be played.
| Value(s) | URL |
| Default value | (none) |
| Compatibility | RealPlayer 5 or later |
In general, the URL can begin with rtsp://, http://, pnm:// or file://. The Virtual Cutter requires that the URL refers to PLAY.PHP, because this programme handles the playback of the selected segment of the media file. This requires the start and end parameters.
<EMBED SRC="http://.../.../play.php/force_real.ram?url=/mijn_bestand.mpg&start=0.1&end=0.1'>
TYPE
Identifies the MIME type of the presentation specifed in the SRC parameter.
| Value(s) | MIME type |
| Default value | (none) |
| Compatibility | RealPlayer 5 or later |
The typical syntax for the MIME type looks like the following:
TYPE="audio/x-pn-realaudio-plugin">
Do not change this value.
WIDTH
Sets the width of the image window or a specified embedded control.
| Value(s) | number of pixels or percentage of browser window size. |
| Default value | (none) |
| Compatibility | RealPlayer 5 or later |
Setting the HEIGHT or WIDTH to zero causes the control to be hidden. If you do not include this parameter in your image window tag definition, the window may appear as a tiny icon because streaming media presentations do not size automatically.