Jump to content

play video


jahlxx

Recommended Posts

Hi, I have a question about video in HTML, sorry if it is not the right place to post.

 

I have this in a UniHTMLFrame:

 

<div id="video_container" align="center">
<video id="lab1_video" autoplay muted loop width="100%"> 
<source src="media/road1.mp4" type="video/mp4">
</video>
</div>
 
This code displays my video as a background in the frame, but when I resize browser window, video remains playing with old dimensions.
This same code as a pure html file works well when browser resizes.
 
Can you give me a hand on this, please?
Link to comment
Share on other sites

Hi, 

Attached test case.

To clarify, if project is built with MainForm as a mfForm, video resizes as browser resizes, but with mfPage option.

To reproduce issue (certainly caused by my poor knowledge), just restore browser and maximize again.

Thanks in advance for your comments and help.

Regards.

htmlframevideo1.rar

Link to comment
Share on other sites

  • 2 weeks later...
  • 4 years later...

Hello!

I'm trying play YouTube video:

<!DOCTYPE html>
<html>
<body>

<iframe id="myVideo"  width="100%" height="100%">
  <src="https://youtu.be/z7vZUIi1pHw" allowfullscreen>
</iframe>

</body>
</html>

But, video not showing. 

UniHTMLFrame is empty:

image.png.e1fd1f36e1726e9b83da733a9bdd90de.png

Is it possible work? 

If "no", may be possible create a new browser window and put link to YouTube video in address string?

Link to comment
Share on other sites

6 hours ago, Артем said:

Hello!

I'm trying play YouTube video:


<!DOCTYPE html>
<html>
<body>

<iframe id="myVideo"  width="100%" height="100%">
  <src="https://youtu.be/z7vZUIi1pHw" allowfullscreen>
</iframe>

</body>
</html>

But, video not showing. 

UniHTMLFrame is empty:

image.png.e1fd1f36e1726e9b83da733a9bdd90de.png

Is it possible work? 

If "no", may be possible create a new browser window and put link to YouTube video in address string?

Hi

You should change your source to embedded one.

Please check https://developers.google.com/youtube/iframe_api_reference

Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
×
×
  • Create New...