Video Player

Getters & Setters

The Mediaflow video player provides a set of getters and setters that let you read and control the player’s state. Use getters to retrieve information like whether the video is currently playing, and setters to update playback settings such as looping, volume, or start position. This page lists the available properties and how to use them.

How to use getters & setters

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nulla euismod, nisl quis lacinia ultricies, nunc nisl ultricies nunc, quis aliquam nisl nunc eu nisl.

var mediaflowplayer = new MFPlayer('#myplayer', '28AFLTPJOS', {
    displayLanguage: 'en'
});
    
mediaflowplayer.player.playing(); // Getter
mediaflowplayer.player.currentTime = 12; // Setter

All getters & setters

Property

Getter

Setter

Description

playing

-

Returns a boolean indicating if the current player has finished playback.

paused

-

Returns a boolean indicating if the current player has finished playback.

stopped

-

Returns a boolean indicating if the current player is stopped.

ended

-

Returns a boolean indicating if the current player has finished playback.

buffered

-

Returns a float between 0 and 1 indicating how much of the media is buffered.

currentTime

Gets or sets the currentTime for the player. The setter accepts a float in seconds.

seeking

-

Returns a boolean indicating if the current player is seeking.

duration

-

Returns the duration for the current media.

volume

Gets or sets the volume for the player. The setter accepts a float between 0 and 1.

muted

Gets or sets the muted state of the player. The setter accepts a boolean.

speed

Gets or sets the speed for the player. The setter accepts a value in the options specified in your config. Generally the minimum should be 0.5.

loop

Gets or sets the current loop state of the player. The setter accepts a boolean.

Mediaflow API

File Selector

Video Player

External