A
A
Alexey Komosa2021-08-29 23:12:18
HTTP Cookies
Alexey Komosa, 2021-08-29 23:12:18

How to save playback position in cookies on html5 audio player?

Can you please tell me how to implement a player with remembering the playback position in cookies? Preferably in HTML5. There is a script, the player is installed there, but it does not remember the time (It is very necessary, please help. To get rid of jsplayer

Answer the question

In order to leave comments, you need to log in

1 answer(s)
V
veryoriginalnickname, 2021-08-29
@komosa

1. Get the player element
2. There is an event timeupdatein the player, you need to put an EventListener on this event on the player element, and inside the function that will process this event, get the time after элемент_плеера.currentTime- this time must be entered into the cookie through some document.cookie.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question