Lightweight integration


Only a light poster will be displayed on the page, and the player itself will be created only after clicking. This mode can positively affect the rendering speed of the page by the browser.

Please enable the PRO option Services / Poster before the player creation and use new PlayerjsPoster({}) instead new Playerjs({})

let player = new PlayerjsPoster({id:"player", file:"URL", poster:"URL", postericon:1});

There you can use an image or a short mp4 video (it will be played when you hover over).

You can also pass postericon:1 to display the launch icon in the center. You can add the posterplay:0 option if you don't want to start automatically on click. You can add the posterscale:0 option if you don't want to scale the poster on hover.

API

You can also use JS API, just call the player via global variable playerjs[id]

playerjs["player"].api("play");

Youtube

You can specify a YouTube video poster like this:

https://img.youtube.com/vi/videoID/maxresdefault.jpg

19.8.92024 © PlayerJS

Sign up free

Sign up
By signing up, you agree to Terms of Service
Login if you have an account

Restore password

Restore
Forgot email? Contact us