Consent management

With the consent plugin it is possible to tell the player whether it's allowed to send analytics and store data to browser by the player.

Installation

Manual JavaScript setup

Load the consnet plugin next to the core player.

<script src="//cdn.flowplayer.com/releases/native/3/stable/flowplayer.min.js"></script>
<script src="//cdn.flowplayer.com/releases/native/3/stable/plugins/consent.min.js"></script>

Player and plugins exist in different release versions. Please see the release channel documentation.

OVP managed player

To enable the plugin in the OVP managed async player, declare it in the plugins config object:

{
  /* other configuration */
  "plugins": ["consent"]
}

Configuration

Without any configuration the player will default to not allow any tracking or storage when the consent plugin is included.

The consent plugin is configured with the top level configuration property consent. This is a bitmask property where the possible values can be found from flowplayer.consent.tracking and flowplayer.consent.storage enumerations.

Example:

flowplayer("#player", {
  src: "my-source.mp4",
  consent: flowplayer.consent.tracking.ALL | flowplayer.consent.storage.NONE // Allow all tracking, allow no storage
})

You can use the calculator below to construct the numeric value if you don't want to use the enumerations.

Tracking properties

In order to either turn analytics on or off you can use the flowplayer.consent.tracking enumeration to construct the bitmask value.

Available properties are

    • property
    • description
    • flowplayer.consent.tracking.NONE
    • No analytics or tracking is allowed to be sent by the player.
    • flowplayer.consent.tracking.ALL
    • Analytics tracking is allowed.

Storage properties

By default Flowplayer will use localStorage to store data that needs to persist between sessions. This data includes both functional properties (like volume state) and also data that helps us to identify unique devices for both technical and analytics use cases.

You can use the flowplayer.consent.storage enumeration to control the usage of browser storage.

Available properties are

    • property
    • description
    • flowplayer.consent.storage.NONE
    • No data is allowed to be stored to be used between browser sessions. In other words - setting this value will make the player to write into sessionStorage.
    • flowplayer.consent.storage.ALL
    • Use of localStorage is allowed.

Calculator

Consent value:

flowplayer("#player", {
  src: "my-source.mp4",
  consent: 999999
})
Results