17 December 2015

How to Adding Logo Brand in Video JS v.4 & v5 HTML5

What is Video JS ???
          Video.js is an open source library for working with video on the web, also known as an HTML5 video player. I think , Video JS is the only and the best framework for HTML5 video player.
Read more : http://videojs.com/ .

But , now we will share how to create a brand logo in the video js. And we will using Plugin of Video js.  
Spec :  
v. VideoJS :Video JS 4 or 5.
Plugin        : videojs-logobrand

<!doctype html>
<html>
<head>
 <title>Video.js logobrand example</title>
 <link rel="stylesheet" href="libs/video-js/video-js.css">
 <script src="libs/video-js/video.js"></script>
 <link rel="stylesheet" href="src/videojs.logobrand.css">
 <script src="src/videojs.logobrand.js"></script>
</head>
 <body>
  <video src="http://vjs.zencdn.net/v/oceans.mp4" class="video-js vjs-default-skin" data-setup="{}" controls width="580" height="320"></video>  
  <script>
   // save a reference to the video element
   video = document.querySelector('video'),
   // save a reference to the video.js player for that element
   player = videojs(video);
   // initialize the plugin with some custom options:
   player.logobrand({    
    image: "logo.png",
    destination: "http://www.videojs.com/"
   });  
   
  </script>
  </style>
 </body>
</html>

But , Script above best working on videojs v.4. ,and not work in VideoJs v.5 . How to fix in v.5 ???

We will editing plugin videojs-logobrand.

Open videojs-logobrand.js and look row 18.
var settings = videojs.util.mergeOptions(defaults, options), player = this;

Change to
var settings = videojs.mergeOptions(defaults, options), player = this;

Done.

Download
1. Logobrand for Videojs4
2. Logobrand for Videojs5

7 comments:

  1. Your blog has given me that thing which I never expect to get from all over the websites. Nice post guys!

    Melbourne Web Designer

    ReplyDelete
  2. It's the most important graphic image a company owns, one that summarizes and represents the business - to employees, partners and most importantly of all, to customers. logo design service

    ReplyDelete
  3. Wow, What a Excellent post. I really found this to much informatics. It is what i was searching for.I would like to suggest you that please keep sharing such type of info.
    Flat Minimalist Logo Service

    ReplyDelete
  4. Love to read it,Waiting For More new Update and I Already Read your Recent Post its Great Thanks.
    Logo Service

    ReplyDelete
  5. I needed to thank you for this incredible read!! I unquestionably adored each and every piece of it. I have you bookmarked your site to look at the new stuff you post. Professional Logo

    ReplyDelete
  6. "Such an image is unimportant until your organization can convey to customers what its hidden affiliations are," says Americus Reed II, a promoting teacher at the University of Pennsylvania's Wharton School, who's led look into on the triggers that lead purchasers to relate to and get to be faithful to a brand. graphic design service

    ReplyDelete
  7. outsourcingall.com "Usually I never comment on blogs but your article is so convincing that I never stop myself to say something about it.
    This paragraph gives clear idea for the new viewers of blogging, Thanks you. You’re doing a great job Man, Keep it up.
    web hosting service in bangladesh

    ReplyDelete