If you don't find an answer, please click here to post your question.
Reply
Occasional Contributor
Posts: 7
Registered: ‎07-27-2017
Accepted Solution

2 video contents in One page is not working on v4

I have posted 2 different videos on one page.  Screen showed up but not responding.

embed tag needed to be customized?

Please suggest !!


Accepted Solutions
Ooyalan
Posts: 42
Registered: ‎04-18-2016

Re: 2 video contents in One page is not working on v4

Hello zuzuki,

 

It would be best for you to place the <script src=> tags in head of the page so they are global for both players. Please take a look at the following URLs for creating v4 player:

 

http://help.ooyala.com/video-platform/reference/pbv4_web_examples.html

http://help.ooyala.com/video-platform/reference/pbv4_web_tutorial.html

http://help.ooyala.com/video-platform/concepts/pbv4_gs.html

 

Greetings,

Uriel

View solution in original post


All Replies
Ooyalan
Posts: 42
Registered: ‎04-18-2016

Re: 2 video contents in One page is not working on v4

Hello zuzuki,

 

Here is an example of 2 player being set on the same page, you have to change some parameters on the players for it to work for example:

<div id="container" style="width:640px; height:360px;"></div> // This has to be diferent on both player in the below example I have set the first player div to "container" and the second I have set it to "container2" after that we need to set the corresponding container in the window.pp = OO.Player.create section. I have pointed out the changes that need to be made in my example for 2 players to load.

 


<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<!-- V4 JS core and at least one video plugin is required. Plugins such as skin, discovery and Advertising need to be loaded separately -->
<script src="//player.ooyala.com/static/v4/stable/4.15.7/core.min.js"></script>
<script src="//player.ooyala.com/static/v4/stable/4.15.7/video-plugin/main_html5.min.js"></script>
<script src="//player.ooyala.com/static/v4/stable/4.15.7/video-plugin/osmf_flash.min.js"></script>
<script src="//player.ooyala.com/static/v4/stable/4.15.7/video-plugin/bit_wrapper.min.js"></script>
<!-- Change these html5-skin.min.css and html5-skin.min.js to your local build if necessary -->
<script src="//player.ooyala.com/static/v4/stable/4.15.7/skin-plugin/html5-skin.min.js"></script>
<link rel="stylesheet" href="//player.ooyala.com/static/v4/stable/4.15.7/skin-plugin/html5-skin.min.css"/>
</head>

<body>
<div id"player1div">

<p> Player 1 </p>

</div>
<div id"player1">
<div id="container" style="width:640px; height:360px;"></div>
<script>
var playerParam = {
"pcode": "U5a2cyOqKtMVt-szcGGHnN8-lQk4",
"playerBrandingId": "abdefc5f60044c3fae5126629fdee11f",
"debug":true,
'platform': 'html5',
"skin": {
// config contains the configuration setting for player skin. Change to your local config when necessary.
"config": "//player.ooyala.com/static/v4/stable/4.15.7/skin-plugin/skin.json"
}
};

OO.ready(function() {
window.pp = OO.Player.create('container', 'JyNjFsNzE6gzzftD451Am1GnyT4asu-7', playerParam);
});
</script>

</div>
<div id"player2div">

<p> Player 2 </p>

</div>

<div id"player2">
<div id="container2" style="width:640px; height:360px;"></div>
<script>
var playerParam = {
"pcode": "U5a2cyOqKtMVt-szcGGHnN8-lQk4",
"playerBrandingId": "abdefc5f60044c3fae5126629fdee11f",
"debug":true,
'platform': 'html5',
"skin": {
// config contains the configuration setting for player skin. Change to your local config when necessary.
"config": "//player.ooyala.com/static/v4/stable/4.15.7/skin-plugin/skin.json"
}
};

OO.ready(function() {
window.pp = OO.Player.create('container2', 'F1bmQ3OTE6C8aAHeyYIGAo3CDC41QqDz', playerParam);
});
</script>
</div>

 


</body>
</html>

 

Let us know if this solves your problem. I have also uploaded the working example here: http://urielflores.x10host.com/2players.html

 

Greetings,

Uriel

Occasional Contributor
Posts: 7
Registered: ‎07-27-2017

Re: 2 video contents in One page is not working on v4

 Dear Uriel

 

Thank you for your reply!! It was very helpful.  

I have changed player div to "Conteainer" and "Container2".  

Two video screen showed up on one page, but both movies do not start.  (I click the screen but not working. )  

 

It seems your tag has V4 version(4.15.7) on it.  Is this something to do with it??  

 

my tag

<script src="//player.ooyala.com/static/v4/production/latest/video-plugin/main_html5.min.js"></script>

your tag

<script src="//player.ooyala.com/static/v4/stable/4.15.7/video-plugin/main_html5.min.js"></script>

Please give me any advice!! 

Ooyalan
Posts: 42
Registered: ‎04-18-2016

Re: 2 video contents in One page is not working on v4

Hello zuzuki,

 

Sorry for the late response below is another example using PRODUCTION/LATEST you can see it working here in this URL:

 

http://urielflores.x10host.com/2player.html

If you are still having issues please send me your code I will be glad take a look at it, also if you have a test URL maybe I can see if there is any errores showing in the console log.

 

Hope this new information helps you out please let me know if you are still having issues.

 

Greetings,

Uriel

 

 

<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<!-- V4 JS core and at least one video plugin is required. Plugins such as skin, discovery and Advertising need to be loaded separately -->
<script src="//player.ooyala.com/static/v4/production/latest/core.min.js"></script>
<script src="//player.ooyala.com/static/v4/production/latest/video-plugin/main_html5.min.js"></script>
<script src="//player.ooyala.com/static/v4/production/latest/video-plugin/osmf_flash.min.js"></script>
<script src="//player.ooyala.com/static/v4/production/latest/video-plugin/bit_wrapper.min.js"></script>
<!-- Change these html5-skin.min.css and html5-skin.min.js to your local build if necessary -->
<script src="//player.ooyala.com/static/v4/production/latest/skin-plugin/html5-skin.min.js"></script>
<link rel="stylesheet" href="//player.ooyala.com/static/v4/production/latest/skin-plugin/html5-skin.min.css"/>
</head>
<body>
<div id"player1div">

<p> Player 1 </p>
</div>
<div id"player1">
<div id="container" style="width:640px; height:360px;"></div>
<script>
var playerParam = {
"pcode": "U5a2cyOqKtMVt-szcGGHnN8-lQk4",
"playerBrandingId": "abdefc5f60044c3fae5126629fdee11f",
"debug":true,
'platform': 'html5',
"skin": {
// config contains the configuration setting for player skin. Change to your local config when necessary.
"config": "//player.ooyala.com/static/v4/production/latest/skin-plugin/skin.json"
}
};
OO.ready(function() {
window.pp = OO.Player.create('container', 'JyNjFsNzE6gzzftD451Am1GnyT4asu-7', playerParam);
});
</script>
</div>
<div id"player2div">

<p> Player 2 </p>
</div>
<div id"player2">
<div id="container2" style="width:640px; height:360px;"></div>
<script>
var playerParam = {
"pcode": "U5a2cyOqKtMVt-szcGGHnN8-lQk4",
"playerBrandingId": "abdefc5f60044c3fae5126629fdee11f",
"debug":true,
'platform': 'html5',
"skin": {
// config contains the configuration setting for player skin. Change to your local config when necessary.
"config": "//player.ooyala.com/static/v4/production/latest/skin-plugin/skin.json"
}
};
OO.ready(function() {
window.pp = OO.Player.create('container2', 'F1bmQ3OTE6C8aAHeyYIGAo3CDC41QqDz', playerParam);
});
</script>
</div>


</body>
</html>

Highlighted
Occasional Contributor
Posts: 7
Registered: ‎07-27-2017

Re: 2 video contents in One page is not working on v4

Dear Uriel
Thank you for your quick response. I will try you have just advised. Thank you again.

Occasional Contributor
Posts: 7
Registered: ‎07-27-2017

Re: 2 video contents in One page is not working on v4

Dear Uriel

 

Please give me advice on <script src="XXXX"></script>

As I see your sample code,  every <script src> is placed in <head> part.

 

Instead I embeded <script src=> in <body> part because every tag generated from administrative page  

has <script src=> on it.   I embeded 2 video contents in body part which means two <script src=> on body part. 

 

 

Should I place one <script src=> in <head> part?  or do I have another resolve issue??

Ooyalan
Posts: 42
Registered: ‎04-18-2016

Re: 2 video contents in One page is not working on v4

Hello zuzuki,

 

It would be best for you to place the <script src=> tags in head of the page so they are global for both players. Please take a look at the following URLs for creating v4 player:

 

http://help.ooyala.com/video-platform/reference/pbv4_web_examples.html

http://help.ooyala.com/video-platform/reference/pbv4_web_tutorial.html

http://help.ooyala.com/video-platform/concepts/pbv4_gs.html

 

Greetings,

Uriel

Occasional Contributor
Posts: 7
Registered: ‎07-27-2017

Re: 2 video contents in One page is not working on v4

Dear Uriel

 

Thank you for your quick reply.

placed the <script src=> tags in head of the page, and it worked for both videos!!

 

Thank you again