SOLVED

Re: Embed a video on a landing page using Javascript from Brightcove

Go to solution
Anonymous
Not applicable

Embed a video on a landing page using Javascript from Brightcove

I want to embed a video in a landing page using Javascript code generated by our video hosting platform, Brightcove.  Looking through the help docs and discussions I can only find instructions on how to do it with a YouTube video.  Can you help?

I have tried adding the code using the "edit HTML source" interface but it is not working.  I can see the Javascript code in place in the HTML, but it does not display the video player in edit mode or when I preview the page.

Here's the code I'm using from Brightcove:

<!-- Start of Brightcove Player -->



<div style="display:none">

</div>

<!--
By use of this code snippet, I agree to the Brightcove Publisher T and C
found at https://accounts.brightcove.com/en/terms-and-conditions/.
-->

<script language="JavaScript" type="text/javascript" src="http://admin.brightcove.com/js/BrightcoveExperiences.js"></script>

<object id="myExperience3616197381001" class="BrightcoveExperience">
  <param name="bgcolor" value="#FFFFFF" />
  <param name="width" value="400" />
  <param name="height" value="225" />
  <param name="playerID" value="1009352068001" />
  <param name="playerKey" value="AQ~~,AAAA6ln2Jbk~,0KOYeFggeIKJaiBAXj9gvfwnfOL3ivMe" />
  <param name="isVid" value="true" />
  <param name="isUI" value="true" />
  <param name="dynamicStreaming" value="true" />
 
  <param name="@videoPlayer" value="3616197381001" />
</object>



<!--
This script tag will cause the Brightcove Players defined above it to be created as soon
as the line is read by the browser. If you wish to have the player instantiated only after
the rest of the HTML is processed and the page load is complete, remove the line.
-->
<script type="text/javascript">brightcove.createExperiences();</script>



<!-- End of Brightcove Player -->
Tags (1)
1 ACCEPTED SOLUTION

Accepted Solutions
Anonymous
Not applicable

Re: Embed a video on a landing page using Javascript from Brightcove

Murtza M, thanks for your reply.  But after tinkering with it some more I determined that the code was working properly, but the preview mode for the landing page was not displaying the Javascript video player (and so the code appeared to not be working).  It was only after I approved the page and viewed the approved page that I could see the video player in action.  Not sure if this is a bug in preview mode, but it is pretty confusing and non-intuitive.

View solution in original post

4 REPLIES 4
Anonymous
Not applicable

Re: Embed a video on a landing page using Javascript from Brightcove

Try removing this portion of code:

<!--
This script tag will cause the Brightcove Players defined above it to be created as soon
as the line is read by the browser. If you wish to have the player instantiated only after
the rest of the HTML is processed and the page load is complete, remove the line.
-->
<script type="text/javascript">brightcove.createExperiences();</script>


Anonymous
Not applicable

Re: Embed a video on a landing page using Javascript from Brightcove

Murtza M, thanks for your reply.  But after tinkering with it some more I determined that the code was working properly, but the preview mode for the landing page was not displaying the Javascript video player (and so the code appeared to not be working).  It was only after I approved the page and viewed the approved page that I could see the video player in action.  Not sure if this is a bug in preview mode, but it is pretty confusing and non-intuitive.
Dan_Stevens_
Level 10 - Champion Alumni

Re: Embed a video on a landing page using Javascript from Brightcove

UPDATE:  Disregard my earlier statement.  The video was using http, while our LPs are https.  Now it works.

This isn't working for us.  The structure of our code is identical to the code of the OP.  I've tried everything and cannot get the Brightcove player to display on a Marketo landing page.  Has Marketo stripped this capability back from when it used to work?  Have others been able to embed custom js code - other than YouTube - to include a video on a landing page?

Anonymous
Not applicable

Re: Embed a video on a landing page using Javascript from Brightcove

Hi Bob,
don't know if that's a bug but you always need to take a look at the approved page (not just when using JavaScript, had sometimes also other differences from preview to approved page). But when you know it it's not a big problem just takes a little bit more time.

Best regards

Steffen