• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

I can't pause video while playing

New Here ,
Nov 29, 2022 Nov 29, 2022

Copy link to clipboard

Copied

I wanted to pause video while it plays. 

For example after video started playing it has to be stopped at 21st second.

After it stopped, some button will show up.

If I click on the button, It will start playing from 30th second etc. 

 

PS: I want to use it on the web.

Views

279

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Nov 30, 2022 Nov 30, 2022

Copy link to clipboard

Copied

and how are you playing the video?  in a video component?

 

if yes, what's the component's instance name?

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Nov 30, 2022 Nov 30, 2022

Copy link to clipboard

Copied

Yes, instance name is mainVideoId

If I click on the video, it will start playing. 

So it should be paused or stopped at 21 seconds. 

$('#dom_overlay_container').on('click', '#MainVideoId', function() {
	$('#MainVideoId')[0].play();
}.bind(_this));

 

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Dec 01, 2022 Dec 01, 2022

Copy link to clipboard

Copied

LATEST

$('#dom_overlay_container').on('click', '#MainVideoId', function() {
$('#MainVideoId')[0].play();

setTimeout(stopVideoF,21000);
}.bind(_this));

 

function stopVideoF(){

 

}$('#MainVideoId')[0].stop();

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines