Dailymotion Player Tools

Deprecated API

The API features listed below have been deprecated. We highly recommend you to visit our new Player API page.

Dailymotion Embedded Player Parameters

Overview

Dailymotion's embedded player can be modified using the parameters described in this document. By adding these parameters to the SWF URL, you can customize color, borders, and various player behaviors, including activation of the player's JavaScript API.

There is two sets of parameters. Global parameters are meant to control the application and must be set when loading the swf. Sequence parameters are meant to control a player's sequence. Each time you load a video using the loadVideo method, you can specify those parameters to constomize the video playback.

Global Parameters

enableApi

Values: 0 or 1. Default is 0. Enable the Javascript API by setting this parameter to 1. For more information and instructions on using the Javascript API, see the JavaScript API documentation.

playerapiid

This value may be any alphanumeric string; it is used in conjunction with the JavaScript API. For details see the JavaScript API documentation.

colors

Player color changes may be set using color codes. A color is described by its hexadecimal value (eg: FF0000 for red).

The player refers to 3 colors named :

  • foreground
  • background
  • highlight

To change player's colors you can use the name of the colors as parameters and set them to any hexadecimal value corresponding to the desired color.

Sequence Parameters

related

Values: 0 or 1. Default is 0. Determines if the player loads related videos when the current video begins playback.

explicit

Values: 0 or 1. Default is 1. Determines if the player allows explicit content to be played. This parameter may be added to embed code by platforms which do not want explicit content to be posted by their users.

autoPlay

Values: 0 or 1. Default is 0. Determines if the video will begin playing automatically when the player loads.

autoMute

Values: 0 or 1. Default is 0. Determines if the video will begin muted.

unmuteOnMouseOver

Values: 0 or 1. Default is 0. Determines if the video will unmuted on mouse over. Of course it works only if the player is on automute=1.

start

Values: a number of seconds. Default is 0. Determines if the video will begin playing the video at a given time.

chromeless

Values: 0 or 1. Default is 0. Determines if the player should display controls or not during video playback.

expandVideo

Values: 0 or 1. Default is 0. Determines if the video should be expanded to fit the whole player's size.

forcedQuality

Values: sd, hq, hd720 or hd1080. Default is empty. Determines the quality that must be played by default if available.

allowTimePreview

Values: 0 or 1. Default is 1. Determines if a preview of the video should be displayed above the seeker on mouse roll over.

hideInfos

Values: 0 or 1. Default is 0. Determines if the video's information should be displayed on the start screen.

defaultSubtitle

Value: subtitle's language (fr, en, es, ...). Default is empty. Specify which subtitle should be loaded by default.

withLoading

Values: 0 or 1. Default is 0. Specify if a loader should be displayed during loading times.

loadRelatedInPlace

Values: 0 or 1. Default is 0. Determines if related videos should be loaded in the current player instead of redirecting toward dailymotion's website.

fullscreenOnDoubleClick

Values: 0 or 1. Default is 1. Determines if a double click on the video should target the fullscreen mode or not.

repeat

Example Usage

To use any of the parameters above, add them to the end of a Dailymotion video SWF URL.

The canonical SWF URL should look like this (VIDEO_ID is optional, see loading the player):

http://www.dailymotion.com/swf/VIDEO_ID

SWF URLs can be programmatically accessed through one of the Dailymotion RSS feeds by looking for the type="application/x-shockwave-flash" <media:content> URL. This format will not be available if embedding has been disabled by the uploader.

<media:content url="http://www.dailymotion.com/swf/VIDEO_ID" type="application/x-shockwave-flash" />

To change the color scheme to a nice soft brown theme, modify the two color parameters:

http://www.dailymotion.com/swf/VIDEO_ID&background=493D27&foreground=E8D9AC&highlight=FFFFF0

Now, place the modified URL into your embed code:

<object width="560" height="315">
    <param name="movie" value="http://www.dailymotion.com/swf/video/VIDEO_ID?background=493D27&foreground=E8D9AC&highlight=FFFFF0"></param>
    <param name="allowFullScreen" value="true"></param>
    <param name="allowScriptAccess" value="always"></param>
    <embed type="application/x-shockwave-flash" src="http://www.dailymotion.com/swf/video/VIDEO_ID?background=493D27&foreground=E8D9AC&highlight=FFFFF0" width="560" height="315" allowfullscreen="true" allowscriptaccess="always"></embed>
</object>